forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of rust-lang#80156 - RalfJung:rollup-m3poz8z, r=RalfJung
Rollup of 6 pull requests Successful merges: - rust-lang#80121 (Change the message for `if_let_guard` feature gate) - rust-lang#80130 (docs: Edit rustc_span::symbol::Symbol method) - rust-lang#80135 (Don't allow `const` to begin a nonterminal) - rust-lang#80145 (Fix typo in rustc_typeck docs) - rust-lang#80146 (Edit formatting in Rust Prelude docs) - rust-lang#80147 (Add missing punctuation to std::alloc docs) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
- Loading branch information
Showing
9 changed files
with
42 additions
and
21 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
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
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
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,20 @@ | ||
// check-pass | ||
|
||
macro_rules! exp { | ||
(const $n:expr) => { | ||
$n | ||
}; | ||
} | ||
|
||
macro_rules! stmt { | ||
(exp $e:expr) => { | ||
$e | ||
}; | ||
(exp $($t:tt)+) => { | ||
exp!($($t)+) | ||
}; | ||
} | ||
|
||
fn main() { | ||
stmt!(exp const 1); | ||
} |
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