Skip to content

Commit 1da7239

Browse files
committed
Add cfg(true) and cfg(false) to conditional compilation (RFC 3695)
1 parent dda31c8 commit 1da7239

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/conditional-compilation.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ r[cfg.syntax]
77
>       _ConfigurationOption_\
88
>    | _ConfigurationAll_\
99
>    | _ConfigurationAny_\
10-
>    | _ConfigurationNot_
10+
>    | _ConfigurationNot_\
11+
>    | `true` | `false`
1112
>
1213
> _ConfigurationOption_ :\
1314
> &nbsp;&nbsp; [IDENTIFIER]&nbsp;(`=` ([STRING_LITERAL] | [RAW_STRING_LITERAL]))<sup>?</sup>
@@ -49,6 +50,9 @@ r[cfg.predicate.any]
4950
r[cfg.predicate.not]
5051
* `not()` with a configuration predicate. It is true if its predicate is false and false if its predicate is true.
5152

53+
r[cfg.predicate.literal]
54+
* `true` or `false` literals, which are always `true`/`false` respectively.
55+
5256
r[cfg.option-spec]
5357
_Configuration options_ are either names or key-value pairs, and are either set or unset.
5458

0 commit comments

Comments
 (0)