diff options
author | Peter Varga <pvarga@inf.u-szeged.hu> | 2022-11-15 15:49:04 +0100 |
---|---|---|
committer | Peter Varga <pvarga@inf.u-szeged.hu> | 2022-11-16 07:54:47 +0000 |
commit | 6e6144b33f415855cc780b23ef8baeca767e56a1 (patch) | |
tree | 13899e526c44d81a9c104e8a1d4cbdd90e441678 | |
parent | 1cf88f1e0504dd99992018d882633291bcce36c8 (diff) | |
download | qtwebengine-chromium-6e6144b33f415855cc780b23ef8baeca767e56a1.tar.gz |
[Backport] GCC: disable unsupported annotate attribute
Creates a lot of noise in non-official builds.
Bug: 819294
Change-Id: I900c588625751b4f82c52e1306c487a822d8e8d8
Review-URL: https://chromium-review.googlesource.com/c/chromium/src/+/3941629
Cr-Commit-Position: refs/heads/main@{#1057012}
Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/443566
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
-rw-r--r-- | chromium/base/memory/raw_ptr_exclusion.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/chromium/base/memory/raw_ptr_exclusion.h b/chromium/base/memory/raw_ptr_exclusion.h index 37e9eac49cd..2cfaefc52e0 100644 --- a/chromium/base/memory/raw_ptr_exclusion.h +++ b/chromium/base/memory/raw_ptr_exclusion.h @@ -6,7 +6,9 @@ #define BASE_MEMORY_RAW_PTR_EXCLUSION_H_ #include "build/build_config.h" +#include "base/compiler_specific.h" +#if HAS_ATTRIBUTE(annotate) #if defined(OFFICIAL_BUILD) // The annotation changed compiler output and increased binary size so disable // for official builds. @@ -17,5 +19,8 @@ // Example: RAW_PTR_EXCLUSION Foo* foo_; #define RAW_PTR_EXCLUSION __attribute__((annotate("raw_ptr_exclusion"))) #endif +#else +#define RAW_PTR_EXCLUSION +#endif #endif // BASE_MEMORY_RAW_PTR_EXCLUSION_H_ |