Skip to content

Commit

Permalink
Disable warning for missing-field-initializers as well for clang.
Browse files Browse the repository at this point in the history
The same warning shows up with clang++. Tested with clang-16 and clang-17.

Without that, my particular application with warnings turned on
and -Werror fails.
  • Loading branch information
hzeller committed Feb 18, 2024
1 parent d00d1e9 commit b32d925
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion re2/re2.h
Original file line number Diff line number Diff line change
Expand Up @@ -972,7 +972,7 @@ inline RE2::Arg RE2::Octal(T* ptr) {
}

// Silence warnings about missing initializers for members of LazyRE2.
#if !defined(__clang__) && defined(__GNUC__)
#if defined(__clang__) || defined(__GNUC__)
#pragma GCC diagnostic ignored "-Wmissing-field-initializers"
#endif

Expand Down

0 comments on commit b32d925

Please sign in to comment.