Title
Restrictions on use of alignas
Status
c++17
Section
9.12.1 [dcl.attr.grammar]
Submitter
Richard Smith

Created on 2015-11-30.00:00:00 last changed 36 months ago

Messages

Date: 2016-11-15.00:00:00

Proposed resolution (November, 2016):

Change 9.12.1 [dcl.attr.grammar] paragraph 5 as follows:

Each attribute-specifier-seq is said to appertain to some entity or statement, identified by the syntactic context where it appears (Clause Clause 8 [stmt.stmt], Clause Clause 9 [dcl.dcl], Clause 9.3 [dcl.decl]). If an attribute-specifier-seq that appertains to some entity or statement contains an attribute or alignment-specifier that is not allowed to apply to that entity or statement, the program is ill-formed. If an attribute-specifier-seq appertains to a friend declaration (11.8.4 [class.friend]), that declaration shall be a definition. No attribute-specifier-seq shall appertain to an explicit instantiation (13.9.3 [temp.explicit]).
Date: 2017-02-15.00:00:00

[Adopted at the February/March, 2017 meeting.]

According to 9.12.1 [dcl.attr.grammar] paragraph 5, a program is ill-formed if an attribute appertains to an entity or statement to which it is not allowed to apply. Presumably an alignment-specifier should have the same restriction.

History
Date User Action Args
2018-02-27 00:00:00adminsetstatus: ready -> c++17
2017-02-06 00:00:00adminsetmessages: + msg5716
2015-11-30 00:00:00admincreate