summaryrefslogtreecommitdiff
path: root/absl/base/internal
diff options
context:
space:
mode:
authorGravatar Derek Mauro <dmauro@google.com>2022-04-25 08:40:42 -0700
committerGravatar Copybara-Service <copybara-worker@google.com>2022-04-25 08:41:33 -0700
commit731689ffc2ad7bb95cc86b5b6160dbe7858f27a0 (patch)
tree6d7c44c1f4532059c1d60b919c70b91457d80361 /absl/base/internal
parent189074734aa1cf774ba2f6956b90f3f6e5680e8e (diff)
Adds ABSL_CONST_INIT to initializing declarations where it is missing
Fixes #1159 PiperOrigin-RevId: 444278141 Change-Id: Iae055fe78b438c31150a9e7601b734f4981f002e
Diffstat (limited to 'absl/base/internal')
-rw-r--r--absl/base/internal/thread_identity.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/absl/base/internal/thread_identity.cc b/absl/base/internal/thread_identity.cc
index 9950e63a..db46aafb 100644
--- a/absl/base/internal/thread_identity.cc
+++ b/absl/base/internal/thread_identity.cc
@@ -56,6 +56,7 @@ void AllocateThreadIdentityKey(ThreadIdentityReclaimerFunction reclaimer) {
// *different* instances of this ptr.
// Apple platforms have the visibility attribute, but issue a compile warning
// that protected visibility is unsupported.
+ABSL_CONST_INIT // Must come before __attribute__((visibility("protected")))
#if ABSL_HAVE_ATTRIBUTE(visibility) && !defined(__APPLE__)
__attribute__((visibility("protected")))
#endif // ABSL_HAVE_ATTRIBUTE(visibility) && !defined(__APPLE__)