Change some terminology around keywords and reserved identifiers
This commit is contained in:
parent
e03948ef3e
commit
b33fd6d759
7 changed files with 99 additions and 109 deletions
|
|
@ -10,11 +10,11 @@
|
|||
|
||||
macro_rules! m {
|
||||
() => {
|
||||
struct $crate {} //~ ERROR expected identifier, found keyword `$crate`
|
||||
struct $crate {} //~ ERROR expected identifier, found reserved identifier `$crate`
|
||||
|
||||
use $crate; // OK
|
||||
//~^ WARN `$crate` may not be imported
|
||||
use $crate as $crate; //~ ERROR expected identifier, found keyword `$crate`
|
||||
use $crate as $crate; //~ ERROR expected identifier, found reserved identifier `$crate`
|
||||
//~^ WARN `$crate` may not be imported
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
// compile-flags: -Z parse-only
|
||||
|
||||
fn macro() { //~ ERROR `macro` is a reserved keyword
|
||||
fn macro() { //~ ERROR expected identifier, found reserved keyword `macro`
|
||||
}
|
||||
|
||||
pub fn main() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue