[Bug c++/88362] attribute aligned silently ignored on C++ references
joseph at codesourcery dot com
gcc-bugzilla@gcc.gnu.org
Wed Dec 5 17:20:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88362
--- Comment #4 from joseph at codesourcery dot com <joseph at codesourcery dot com> ---
It's not very clear to me what an aligned attribute on a reference, or a
check of the alignment of a reference, should mean anyway.
Note that in some places, [[]]-style attributes appertain to different
syntactic constructs than __attribute__ appertains in the same place (and
in any case, what [[]] appertains to is more precisely defined, whereas
what __attribute__ appertains to is what keeps compatibility with existing
code).
C++ alignas can be applied to references, but I don't see anything in
[dcl.align] to clarify what it means there - does it align the referenced
type (so that it's only valid to bind the reference to an object that
itself is sufficiently aligned), or something else?
More information about the Gcc-bugs
mailing list