2 ms·
Off topic, but TIL pragma once isn't part of the standard. I was wondering why clang-tidy didn't have a check for it...
by hoten 4y ago
Off topic, but TIL pragma once isn't part of the standard. I was wondering why clang-tidy didn't have a check for it...
- SAI_Peregrinus 4y agoC 11 standard, 6.10.6 "Pragma directive" A preprocessing directive of the form `#pragma pp-tokens_opt new-line` where the preprocessing token STDC does not immediately follow pragma in the directive (prior to any macro replacement) causes the implementation to behave in an implementation-defined manner. ... Pragma directives are only part of the C standard if followed by STDC. The ISO C++ standard does not require any pragmas to be supported at all, though most compilers will support at least the ones required by C even in C++ mode.