Skip to content

Commit 21c67ed

Browse files
committed
CWG3018 Validity of defined in __has_embed
1 parent af9bc2b commit 21c67ed

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

source/preprocessor.tex

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -391,6 +391,8 @@
391391
\grammarterm{has-attribute-expression}{s},
392392
and/or \grammarterm{has-embed-expression}{s}
393393
as unary operator expressions.
394+
A \grammarterm{defined-macro-expression} shall not appear
395+
within a \grammarterm{has-include-expression} or \grammarterm{has-embed-expression}.
394396

395397
\pnum
396398
A \grammarterm{defined-macro-expression} evaluates to \tcode{1}
@@ -1047,15 +1049,17 @@
10471049
\end{example}
10481050

10491051
\rSec2[cpp.embed.param]{Embed parameters}
1052+
10501053
\rSec3[cpp.embed.param.limit]{limit parameter}
1054+
10511055
\pnum
10521056
An \grammarterm{embed-parameter} of the form
10531057
\tcode{limit (} \grammarterm{pp-balanced-token-seq} \tcode{)}
10541058
specifies the
10551059
maximum possible number of elements in the comma-delimited list.
10561060
It shall appear at most once in the \grammarterm{embed-parameter-seq}.
1057-
The token \tcode{defined} shall not appear in the
1058-
\grammarterm{constant-expression}.
1061+
The preprocessing token \tcode{defined} shall not appear in the
1062+
\grammarterm{pp-balanced-token-seq}.
10591063

10601064
\pnum
10611065
The \grammarterm{pp-balanced-token-seq} is evaluated as a

0 commit comments

Comments
 (0)