mark as unused some variables with cpp-derived names

Summary: as above

Test Plan:
  Run "make EXTRA_CXXFLAGS='-W -Wextra'" and see fewer errors.

Reviewers: ljin, sdong, igor.sugak, igor

Reviewed By: igor

Subscribers: dhruba

Differential Revision: https://reviews.facebook.net/D33753
main
Jim Meyering 10 years ago
parent c6d54b5037
commit 1b4082581c
  1. 3
      util/benchharness.h
  2. 5
      util/testharness.h

@ -154,7 +154,8 @@ AddBenchmark(const char* file, const char* name, Lambda&& lambda) {
#define FB_CONCATENATE_IMPL(s1, s2) s1##s2
#define FB_CONCATENATE(s1, s2) FB_CONCATENATE_IMPL(s1, s2)
#define FB_ANONYMOUS_VARIABLE(str) FB_CONCATENATE(str, __LINE__)
#define FB_ANONYMOUS_VARIABLE(str) \
FB_CONCATENATE(str, __LINE__ __attribute__((__unused__)))
#define FB_STRINGIZE(x) #x

@ -182,8 +182,9 @@ class TesterHelper {
t._Run(); \
} \
}; \
bool TCONCAT(_Test_ignored_, name) = ::rocksdb::test::RegisterTest( \
#base, #name, &TCONCAT(_Test_, name)::_RunIt); \
bool TCONCAT(_Test_ignored_, name) __attribute__((__unused__)) \
= ::rocksdb::test::RegisterTest(#base, #name, \
&TCONCAT(_Test_, name)::_RunIt); \
void TCONCAT(_Test_, name)::_Run()
// Register the specified test. Typically not used directly, but

Loading…
Cancel
Save