mirror of
https://github.com/rust-lang/rust.git
synced 2026-04-27 18:57:42 +03:00
Fix new merge conflict
This commit is contained in:
@@ -26,7 +26,10 @@ fn main() {
|
||||
|
||||
macro_rules! make {
|
||||
($name:ident) => { #[doc(alias = $name)] pub struct S; }
|
||||
//~^ ERROR: expected unsuffixed literal, found identifier `nickname`
|
||||
//~^ ERROR: expected a literal (`1u8`, `1.0f32`, `"string"`, etc.) here, found expression
|
||||
//~| NOTE: expressions are not allowed here
|
||||
//~| HELP: surround the identifier with quotation marks to make it into a string literal
|
||||
}
|
||||
|
||||
make!(nickname); //~ NOTE: in this expansion
|
||||
//~^ NOTE in this expansion of make
|
||||
|
||||
@@ -20,14 +20,31 @@ help: surround the identifier with quotation marks to make it into a string lite
|
||||
LL | #[cfg(key="foo bar baz")]
|
||||
| + +
|
||||
|
||||
error: expected a literal (`1u8`, `1.0f32`, `"string"`, etc.) here, found expression
|
||||
--> $DIR/attr-unquoted-ident.rs:18:15
|
||||
|
|
||||
LL | #[cfg(key=foo 1 bar 2.0 baz.)]
|
||||
| ^^^ expressions are not allowed here
|
||||
|
|
||||
help: surround the identifier with quotation marks to make it into a string literal
|
||||
|
|
||||
LL | #[cfg(key="foo 1 bar 2.0 baz.")]
|
||||
| + +
|
||||
|
||||
error: expected a literal (`1u8`, `1.0f32`, `"string"`, etc.) here, found expression
|
||||
--> $DIR/attr-unquoted-ident.rs:28:38
|
||||
|
|
||||
LL | ($name:ident) => { #[doc(alias = $name)] pub struct S; }
|
||||
| ^^^^^
|
||||
| ^^^^^ expressions are not allowed here
|
||||
...
|
||||
LL | make!(nickname);
|
||||
| --------------- in this macro invocation
|
||||
|
|
||||
= note: this error originates in the macro `make` (in Nightly builds, run with -Z macro-backtrace for more info)
|
||||
help: surround the identifier with quotation marks to make it into a string literal
|
||||
|
|
||||
LL | ($name:ident) => { #[doc(alias = "$name")] pub struct S; }
|
||||
| + +
|
||||
|
||||
error: aborting due to 4 previous errors
|
||||
|
||||
|
||||
Reference in New Issue
Block a user