Update numeric lifetime test

This commit is contained in:
许杰友 Jieyou Xu (Joe)
2023-02-14 18:17:59 +08:00
parent 380fa26413
commit 98b82aedba
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
struct S<'1> { s: &'1 usize }
//~^ ERROR lifetimes cannot start with a number
//~| ERROR lifetimes cannot start with a number
//~^ ERROR lifetimes or labels cannot start with a number
//~| ERROR lifetimes or labels cannot start with a number
fn main() {
// verify that the parse error doesn't stop type checking
let x: usize = "";
+2 -2
View File
@@ -6,13 +6,13 @@ LL | let x: usize = "";
| |
| expected due to this
error: lifetimes cannot start with a number
error: lifetimes or labels cannot start with a number
--> $DIR/numeric-lifetime.rs:1:10
|
LL | struct S<'1> { s: &'1 usize }
| ^^
error: lifetimes cannot start with a number
error: lifetimes or labels cannot start with a number
--> $DIR/numeric-lifetime.rs:1:20
|
LL | struct S<'1> { s: &'1 usize }