Commit 8148fd96 authored by Tomas Popela's avatar Tomas Popela Committed by Commit Bot

GCC: Can't use alignas() together with __attribute__()

It's because GCC has problems when mixing the alignas() together with
__attribute__() (that is used to export the symbols). The best
solution is to use ALIGNAS() macro from //base/compiler_specific.h
together with alignof() to have the equal functionality that compiles on
GCC as well as on clang.

This is a regression after https://crrev.com/659933.

Bug: 994581
Change-Id: Ia376866ff9ac57d52d2e907fa325ae5a51893d07
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1758064Reviewed-by: default avatarEric Willigers <ericwilligers@chromium.org>
Commit-Queue: Eric Willigers <ericwilligers@chromium.org>
Commit-Queue: Tomáš Popela <tomas.popela@gmail.com>
Auto-Submit: Tomáš Popela <tomas.popela@gmail.com>
Cr-Commit-Position: refs/heads/master@{#688417}
parent 0359f642
......@@ -175,8 +175,8 @@ class CSSLazyPropertyParser
DISALLOW_COPY_AND_ASSIGN(CSSLazyPropertyParser);
};
class CORE_EXPORT alignas(Member<const CSSValue>) alignas(
CSSPropertyValueMetadata) ImmutableCSSPropertyValueSet
class CORE_EXPORT ALIGNAS(alignof(Member<const CSSValue>))
ALIGNAS(alignof(CSSPropertyValueMetadata)) ImmutableCSSPropertyValueSet
: public CSSPropertyValueSet {
public:
ImmutableCSSPropertyValueSet(const CSSPropertyValue*,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment