Title
Alignment of references
Status
open
Section
9.13.2 [dcl.align]
Submitter
Brian Bi

Created on 2025-05-02.00:00:00 last changed 4 days ago

Messages

Date: 2025-05-05.20:49:06

Suggested resolution:

Change in 9.13.2 [dcl.align] paragraph 1 as follows:

An alignment-specifier may be applied to a variable or to a class non-static data member, but it shall not be applied to a reference, a bit-field, a function parameter, or an exception-declaration (14.4 [except.handle]). An alignment-specifier may also be applied to the declaration of a class (in an elaborated-type-specifier (9.2.9.5 [dcl.type.elab]) or class-head (Clause 11 [class] 11.1 [class.pre]), respectively). An alignment-specifier with an ellipsis is a pack expansion (13.7.4 [temp.variadic]).
Date: 2025-05-02.00:00:00

(From submission #703.)

Per 9.13.2 [dcl.align] paragraph 1, an alignment-specifier may be applied to a reference. However, it is unclear what "alignment requirements for a reference" actually means. There is implementation divergence

History
Date User Action Args
2025-05-05 20:49:06adminsetmessages: + msg8021
2025-05-02 00:00:00admincreate