Description
GCC (AFAICT since version 9.1) accepts the no_sanitize
attribute in both __attribute__((no_sanitize("...")))
and [[gnu::no_sanitize("...")]]
spellings. Clang doesn't accept [[gnu::no_sanitize(...)]]
but only [[clang::no_sanitize("...")]]
so it's not possible to use modern C++ attribute syntax in source code compatible with both compilers without #ifdef
s. Clang should accept both spellings in C++11 attribute syntax.