Skip to content

Commit 9c3f477

Browse files
committed
Update cfg.cfg_attr.behaviour
This updates the rule to match the style, moves it to match the template, does a slight rewording. The sentence about the example was moved in a previous commit.
1 parent b8a3c10 commit 9c3f477

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/conditional-compilation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -413,11 +413,11 @@ The `cfg_attr` attribute is allowed anywhere attributes are allowed.
413413
r[cfg.cfg_attr.duplicates]
414414
Multiple `cfg_attr` attributes may be specified.
415415

416-
r[cfg.cfg_attr.behaviour]
417-
When the configuration predicate is true, this attribute expands out to the attributes listed after the predicate. For example, the following module will either be found at `linux.rs` or `windows.rs` based on the target.
418416
r[cfg.cfg_attr.attr-restriction]
419417
The [`crate_type`] and [`crate_name`] attributes cannot be used with `cfg_attr`.
420418

419+
r[cfg.cfg_attr.behavior]
420+
When the configuration predicate is true, `cfg_attr` expands out to the attributes listed after the predicate.
421421

422422
r[cfg.cfg_attr.attribute-list]
423423
Zero, one, or more attributes may be listed. Multiple attributes will each be expanded into separate attributes. For example:

0 commit comments

Comments
 (0)