3 ms·
A reasonable compiler would let you turn off a specific warning for a section of code.
by fluoridation 3y ago
A reasonable compiler would let you turn off a specific warning for a section of code.
- torstenvl 3y agoThey pretty much all do. #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wwhatever" // code #pragma clang diagnostic pop
- fluoridation 3y agoI was going to comment that GCC doesn't, but it seems it was added as some point since the last time I checked. I know at one time GCC had as a policy not to allow doing that.
- torstenvl 3y agoHere's an example: https://pastebin.com/raw/fH0Lj2Zb https://pastebin.com/raw/fH0Lj2Zb