error: expected type, found `{` --> $DIR/macro-fail.rs:33:27 | LL | fn make_marker() -> impl Marker { | ---------------------- | | | this macro call doesn't expand to a type | in this macro invocation ... LL | ($rusty: ident) => {{ let $rusty = 3; *&$rusty }} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected type | = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) error: expected type, found `{` --> $DIR/macro-fail.rs:33:27 | LL | Example:: | ---------------------- | | | this macro call doesn't expand to a type | in this macro invocation ... LL | ($rusty: ident) => {{ let $rusty = 3; *&$rusty }} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected type | = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) error: expected type, found `{` --> $DIR/macro-fail.rs:6:10 | LL | () => {{ | __________^ LL | | LL | | const X: usize = 1337; LL | | X LL | | }} | |___^ expected type ... LL | let _fail = Example::; | ----------------- | | | this macro call doesn't expand to a type | in this macro invocation | = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) error: unexpected end of macro invocation --> $DIR/macro-fail.rs:44:25 | LL | macro_rules! gimme_a_const { | -------------------------- when calling this macro ... LL | let _fail = Example::; | ^^^^^^^^^^^^^^^^ missing tokens in macro arguments error[E0107]: wrong number of const arguments: expected 1, found 0 --> $DIR/macro-fail.rs:16:26 | LL | fn make_marker() -> impl Marker { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 1 const argument error[E0107]: wrong number of type arguments: expected 0, found 1 --> $DIR/macro-fail.rs:16:33 | LL | fn make_marker() -> impl Marker { | ^^^^^^^^^^^^^^^^^^^^^^ unexpected type argument error[E0107]: wrong number of const arguments: expected 1, found 0 --> $DIR/macro-fail.rs:19:3 | LL | Example:: | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 1 const argument error[E0107]: wrong number of type arguments: expected 0, found 1 --> $DIR/macro-fail.rs:19:13 | LL | Example:: | ^^^^^^^^^^^^^^^^^^^^^^ unexpected type argument error[E0107]: wrong number of const arguments: expected 1, found 0 --> $DIR/macro-fail.rs:40:15 | LL | let _fail = Example::; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 1 const argument error[E0107]: wrong number of type arguments: expected 0, found 1 --> $DIR/macro-fail.rs:40:25 | LL | let _fail = Example::; | ^^^^^^^^^^^^^^^^^ unexpected type argument error[E0107]: wrong number of const arguments: expected 1, found 0 --> $DIR/macro-fail.rs:44:15 | LL | let _fail = Example::; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected 1 const argument error[E0107]: wrong number of type arguments: expected 0, found 1 --> $DIR/macro-fail.rs:44:25 | LL | let _fail = Example::; | ^^^^^^^^^^^^^^^^ unexpected type argument error: aborting due to 12 previous errors For more information about this error, try `rustc --explain E0107`.