diff options
author | Randolf J <34705014+jun-sheaf@users.noreply.github.com> | 2022-10-05 22:51:24 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-05 22:51:24 +0200 |
commit | beaec233795725fea58fd88b2f9271aa7decabce (patch) | |
tree | 73a75125b0787d3b47f32ae29b079bec864b9102 /absl/base/internal/thread_annotations.h | |
parent | bf2bf60a3e29f159c8aa513d58cbe65f3f633bb6 (diff) | |
parent | 1fd600dc490db4db0ebf7bcc629d8914e828467e (diff) | |
download | abseil-beaec233795725fea58fd88b2f9271aa7decabce.tar.gz abseil-beaec233795725fea58fd88b2f9271aa7decabce.tar.bz2 abseil-beaec233795725fea58fd88b2f9271aa7decabce.zip |
Merge branch 'abseil:master' into patch-1
Diffstat (limited to 'absl/base/internal/thread_annotations.h')
-rw-r--r-- | absl/base/internal/thread_annotations.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/absl/base/internal/thread_annotations.h b/absl/base/internal/thread_annotations.h index 4dab6a9c..8c5c67e0 100644 --- a/absl/base/internal/thread_annotations.h +++ b/absl/base/internal/thread_annotations.h @@ -38,6 +38,13 @@ #ifndef ABSL_BASE_INTERNAL_THREAD_ANNOTATIONS_H_ #define ABSL_BASE_INTERNAL_THREAD_ANNOTATIONS_H_ +// ABSL_LEGACY_THREAD_ANNOTATIONS is a *temporary* compatibility macro that can +// be defined on the compile command-line to restore the legacy spellings of the +// thread annotations macros/functions. The macros in this file are available +// under ABSL_ prefixed spellings in absl/base/thread_annotations.h. This macro +// and the legacy spellings will be removed in the future. +#ifdef ABSL_LEGACY_THREAD_ANNOTATIONS + #if defined(__clang__) #define THREAD_ANNOTATION_ATTRIBUTE__(x) __attribute__((x)) #else @@ -268,4 +275,6 @@ inline T& ts_unchecked_read(T& v) NO_THREAD_SAFETY_ANALYSIS { } // namespace thread_safety_analysis +#endif // defined(ABSL_LEGACY_THREAD_ANNOTATIONS) + #endif // ABSL_BASE_INTERNAL_THREAD_ANNOTATIONS_H_ |