2020-02-23 03:24:30 -06:00
|
|
|
error: an extern crate cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:9:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a `use` import cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:10:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a static item cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:11:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a module cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:14:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern block cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:15:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an enum cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:17:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a struct cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:18:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a union cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:19:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:20:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait alias cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:21:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:25:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
2020-02-22 01:55:01 -06:00
|
|
|
LL | default default!();
|
2020-02-21 21:53:02 -06:00
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
2020-02-21 23:57:31 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:26:5
|
|
|
|
|
|
2020-02-22 01:55:01 -06:00
|
|
|
LL | default default::foo::bar!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:27:5
|
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:28:5
|
|
|
|
|
|
2020-02-21 23:57:31 -06:00
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern crate cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:33:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern crate is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:33:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a `use` import cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:35:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: `use` import is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:35:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a static item cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:37:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
|
|
|
error: extern items cannot be `const`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:38:19
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default const foo: u8;
|
|
|
|
| --------------^^^
|
|
|
|
| |
|
|
|
|
| help: try using a static value: `static`
|
|
|
|
|
|
|
|
|
= note: for more information, visit https://doc.rust-lang.org/std/keyword.extern.html
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a module cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:41:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: module is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:41:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern block cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:43:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern block is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:43:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an enum cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:46:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: enum is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:46:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a struct cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:48:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: struct is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:48:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a union cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:50:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: union is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:50:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:52:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:52:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait alias cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:54:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait alias is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:54:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: implementation is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:56:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default impl foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:60:5
|
|
|
|
|
|
|
|
|
LL | default default!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:61:5
|
|
|
|
|
|
|
|
|
LL | default default::foo::bar!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:62:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:62:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:64:5
|
2020-02-21 21:53:02 -06:00
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `extern` blocks
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:64:5
|
2020-02-21 23:57:31 -06:00
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern crate cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:70:5
|
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern crate is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:70:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a `use` import cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:72:5
|
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: `use` import is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:72:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a static item cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:74:5
|
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-22 01:16:39 -06:00
|
|
|
error: associated `static` items are not allowed
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:74:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a module cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:78:5
|
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: module is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:78:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern block cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:80:5
|
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern block is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:80:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an enum cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:83:5
|
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: enum is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:83:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a struct cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:85:5
|
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: struct is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:85:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a union cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:87:5
|
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: union is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:87:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:89:5
|
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:89:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait alias cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:91:5
|
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait alias is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:91:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: implementation is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:93:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default impl foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:97:5
|
|
|
|
|
|
|
|
|
LL | default default!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
|
|
|
error: an item macro invocation cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:98:5
|
|
|
|
|
|
|
|
|
LL | default default::foo::bar!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
|
|
|
error: a macro definition cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:99:5
|
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:99:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:101:5
|
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:101:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern crate cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:107:5
|
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern crate is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:107:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default extern crate foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a `use` import cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:109:5
|
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: `use` import is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:109:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default use foo;
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a static item cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:111:5
|
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-22 01:16:39 -06:00
|
|
|
error: associated `static` items are not allowed
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:111:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default static foo: u8;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a module cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:115:5
|
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: module is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:115:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default mod foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an extern block cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:117:5
|
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: extern block is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:117:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default extern "C" {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an enum cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:120:5
|
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: enum is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:120:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default enum foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a struct cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:122:5
|
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: struct is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:122:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default struct foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a union cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:124:5
|
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: union is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:124:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default union foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:126:5
|
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:126:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a trait alias cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:128:5
|
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: trait alias is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:128:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default trait foo = Ord;
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: implementation is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:130:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default impl foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: an item macro invocation cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:134:5
|
|
|
|
|
|
|
|
|
LL | default default!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
|
|
|
error: an item macro invocation cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:135:5
|
|
|
|
|
|
|
|
|
LL | default default::foo::bar!();
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
|
|
|
error: a macro definition cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:136:5
|
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:136:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default macro foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: a macro definition cannot be `default`
|
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:138:5
|
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^ `default` because of this
|
|
|
|
|
|
|
|
|
= note: only associated `fn`, `const`, and `type` items can be `default`
|
|
|
|
|
2020-02-23 05:54:00 -06:00
|
|
|
error: macro definition is not supported in `trait`s or `impl`s
|
2020-02-22 01:55:01 -06:00
|
|
|
--> $DIR/default-on-wrong-item-kind.rs:138:5
|
2020-02-22 01:16:39 -06:00
|
|
|
|
|
|
|
|
LL | default macro_rules! foo {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-02-23 03:24:30 -06:00
|
|
|
error: aborting due to 95 previous errors
|
2020-02-21 21:53:02 -06:00
|
|
|
|