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