Skip to content

Commit 84eb3b2

Browse files
estebankcuviper
authored andcommitted
Add ICE regression tests
(cherry picked from commit f6e9fd0)
1 parent ec4a464 commit 84eb3b2

4 files changed

+34
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
macro_rules! x {
2+
($($c:tt)*) => {
3+
$($c)ö* {} //~ ERROR missing condition for `if` expression
4+
};
5+
}
6+
7+
fn main() {
8+
x!(if);
9+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
error: missing condition for `if` expression
2+
--> $DIR/issue-68091-unicode-ident-after-if.rs:3:14
3+
|
4+
LL | $($c)ö* {}
5+
| ^ expected if condition here
6+
7+
error: aborting due to previous error
8+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
macro_rules! x {
2+
($($c:tt)*) => {
3+
$($c)ö* //~ ERROR macro expansion ends with an incomplete expression: expected expression
4+
};
5+
}
6+
7+
fn main() {
8+
x!(!);
9+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
error: macro expansion ends with an incomplete expression: expected expression
2+
--> $DIR/issue-68092-unicode-ident-after-incomplete-expr.rs:3:14
3+
|
4+
LL | $($c)ö*
5+
| ^ expected expression
6+
7+
error: aborting due to previous error
8+

0 commit comments

Comments
 (0)