From bcc11a8918f8cc9b43c9a0dc5da7b52d48452bd3 Mon Sep 17 00:00:00 2001 From: Jeremy Ong Date: Tue, 27 Apr 2021 11:26:09 -0600 Subject: Uses alignas for portability in dynamic_annotations.h (#947) Fixes an MSVC compiler error when address sanitizers are enabled --- absl/base/dynamic_annotations.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'absl/base') diff --git a/absl/base/dynamic_annotations.h b/absl/base/dynamic_annotations.h index 880cbf6e..03d7096b 100644 --- a/absl/base/dynamic_annotations.h +++ b/absl/base/dynamic_annotations.h @@ -471,7 +471,7 @@ using absl::base_internal::ValgrindSlowdown; __sanitizer_annotate_contiguous_container(beg, end, old_mid, new_mid) #define ABSL_ADDRESS_SANITIZER_REDZONE(name) \ struct { \ - char x[8] __attribute__((aligned(8))); \ + alignas(8) char x[8]; \ } name #else -- cgit v1.2.3