mirror of
https://github.com/google/benchmark.git
synced 2025-03-31 06:30:35 +08:00
update names
This commit is contained in:
parent
e96f068a1d
commit
75712367c1
@ -431,14 +431,14 @@ class Benchmark {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Helpers for generating unique variable names
|
// Helpers for generating unique variable names
|
||||||
#define BENCHMARK_PRIVATE_CONCAT(n) \
|
#define BENCHMARK_PRIVATE_NAME(n) \
|
||||||
BENCHMARK_PRIVATE_CONCAT2(_benchmark_, BENCHMARK_PRIVATE_UNIQUE_ID, n)
|
BENCHMARK_PRIVATE_CONCAT(_benchmark_, BENCHMARK_PRIVATE_UNIQUE_ID, n)
|
||||||
#define BENCHMARK_PRIVATE_CONCAT2(a, b, c) BENCHMARK_PRIVATE_CONCAT3(a, b, c)
|
#define BENCHMARK_PRIVATE_CONCAT(a, b, c) BENCHMARK_PRIVATE_CONCAT2(a, b, c)
|
||||||
#define BENCHMARK_PRIVATE_CONCAT3(a, b, c) a##b##c
|
#define BENCHMARK_PRIVATE_CONCAT2(a, b, c) a##b##c
|
||||||
|
|
||||||
#define BENCHMARK_PRIVATE_DECLARE(n) \
|
#define BENCHMARK_PRIVATE_DECLARE(n) \
|
||||||
static ::benchmark::internal::Benchmark* \
|
static ::benchmark::internal::Benchmark* \
|
||||||
BENCHMARK_PRIVATE_CONCAT(n) BENCHMARK_UNUSED
|
BENCHMARK_PRIVATE_NAME(n) BENCHMARK_UNUSED
|
||||||
|
|
||||||
#define BENCHMARK(n) \
|
#define BENCHMARK(n) \
|
||||||
BENCHMARK_PRIVATE_DECLARE(n) = (new ::benchmark::internal::Benchmark(#n, n))
|
BENCHMARK_PRIVATE_DECLARE(n) = (new ::benchmark::internal::Benchmark(#n, n))
|
||||||
|
Loading…
Reference in New Issue
Block a user