-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
cfg_select! + doc comment gives cryptic compiler error #155701
Copy link
Copy link
Open
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsD-confusingDiagnostics: Confusing error or lint that should be reworked.Diagnostics: Confusing error or lint that should be reworked.F-cfg_select`#![feature(cfg_select)]``#![feature(cfg_select)]`T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-diagnosticsArea: Messages for errors, warnings, and lintsArea: Messages for errors, warnings, and lintsD-confusingDiagnostics: Confusing error or lint that should be reworked.Diagnostics: Confusing error or lint that should be reworked.F-cfg_select`#![feature(cfg_select)]``#![feature(cfg_select)]`T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
I tried this code:
I expected to see this happen:
Instead, this happened:
Note that using doc comments on regular match arms works fine, but emits a warning.
Gives:
Meta
rustc --version --verbose: