Skip to content

Commit f302e77

Browse files
committed
Disable -pedantic-errors for Google benchmark
The library uses __COUNTER__ which is an extension; Clang diagnoses the extension now, and this causes problems for the build lab. Hopefully resolves: https://lab.llvm.org/buildbot/#/builders/143/builds/12216
1 parent bb453ac commit f302e77

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

MicroBenchmarks/libs/benchmark/CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,9 @@ else()
199199
add_cxx_compiler_flag(-Wsuggest-override)
200200
endif()
201201
add_cxx_compiler_flag(-pedantic)
202-
add_cxx_compiler_flag(-pedantic-errors)
202+
# Disable -pedantic-errors because of __COUNTER__ use. See
203+
# https://github.com/google/benchmark/issues/2057 for details.
204+
#add_cxx_compiler_flag(-pedantic-errors)
203205
add_cxx_compiler_flag(-Wshorten-64-to-32)
204206
add_cxx_compiler_flag(-fstrict-aliasing)
205207
# Disable warnings regarding deprecated parts of the library while building

0 commit comments

Comments
 (0)