Skip to content

Commit

Permalink
Clang: -Wno-null-conversion for Lexer (#3333)
Browse files Browse the repository at this point in the history
## Summary

Silence a warning in the lexer used in the parser for Clang 12.

## Additional background

```
/g/g90/huebl1/src/warpx/build_lassen/_deps/fetchedamrex-src/Src/Base/Parser/amrex_iparser.lex.nolint.H:2010:68: warning: implicit conversion of NULL constant to 'bool' [-Wnull-conversion]
while ((yy_buffer_stack) ? yy_buffer_stack[yy_buffer_stack_top] : (__null)) { 
...
```
et al.
  • Loading branch information
ax3l authored May 29, 2023
1 parent 76d6d34 commit 07f87b0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Src/Base/Parser/amrex_parser.lex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#pragma GCC diagnostic ignored "-Wfloat-conversion"
#pragma GCC diagnostic ignored "-Wsign-compare"
#elif defined(__clang__)
#pragma clang diagnostic ignored "-Wnull-conversion"
#pragma clang diagnostic ignored "-Wnull-dereference"
#pragma clang diagnostic ignored "-Wunreachable-code"
#pragma clang diagnostic ignored "-Wfloat-conversion"
Expand Down

0 comments on commit 07f87b0

Please sign in to comment.