-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of #126735 - bvanjoi:fix-126647, r=petrochenkov
collect attrs in const block expr Fixes #126516 Fixes #126647 It was forgotten to collect these attributes in the const block expression. r? `@petrochenkov`
- Loading branch information
Showing
3 changed files
with
20 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// issue#126516 | ||
// issue#126647 | ||
|
||
fn main() { | ||
const { | ||
#![path = foo!()] | ||
//~^ ERROR: cannot find macro `foo` in this scope | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
error: cannot find macro `foo` in this scope | ||
--> $DIR/path-attr-in-const-block.rs:6:19 | ||
| | ||
LL | #![path = foo!()] | ||
| ^^^ | ||
|
||
error: aborting due to 1 previous error | ||
|