2017-04-13 22:37:05 +03:00
|
|
|
error: missing `fn`, `type`, or `const` for impl-item declaration
|
|
|
|
--> $DIR/issue-40006.rs:11:9
|
2017-03-24 23:00:21 -07:00
|
|
|
|
|
2017-04-13 22:37:05 +03:00
|
|
|
11 | impl X {
|
2017-04-14 16:38:10 -07:00
|
|
|
| _________^
|
2017-04-13 22:37:05 +03:00
|
|
|
12 | | Y
|
2017-04-14 16:38:10 -07:00
|
|
|
| |____^ missing `fn`, `type`, or `const`
|
2017-04-13 22:37:05 +03:00
|
|
|
|
|
|
|
error: missing `fn`, `type`, or `const` for trait-item declaration
|
|
|
|
--> $DIR/issue-40006.rs:17:10
|
|
|
|
|
|
|
|
|
17 | trait X {
|
2017-04-14 16:38:10 -07:00
|
|
|
| __________^
|
2017-04-13 22:37:05 +03:00
|
|
|
18 | | X() {}
|
2017-04-14 16:38:10 -07:00
|
|
|
| |____^ missing `fn`, `type`, or `const`
|
2017-04-13 22:37:05 +03:00
|
|
|
|
|
|
|
error: expected `[`, found `#`
|
|
|
|
--> $DIR/issue-40006.rs:19:17
|
|
|
|
|
|
|
|
|
19 | fn xxx() { ### }
|
|
|
|
| ^
|
|
|
|
|
|
|
|
error: missing `fn`, `type`, or `const` for trait-item declaration
|
|
|
|
--> $DIR/issue-40006.rs:19:21
|
|
|
|
|
|
|
|
|
19 | fn xxx() { ### }
|
2017-04-14 16:38:10 -07:00
|
|
|
| _____________________^
|
2017-04-13 22:37:05 +03:00
|
|
|
20 | | L = M;
|
2017-04-14 16:38:10 -07:00
|
|
|
| |____^ missing `fn`, `type`, or `const`
|
2017-04-13 22:37:05 +03:00
|
|
|
|
|
|
|
error: missing `fn`, `type`, or `const` for trait-item declaration
|
|
|
|
--> $DIR/issue-40006.rs:20:11
|
|
|
|
|
|
|
|
|
20 | L = M;
|
2017-04-14 16:38:10 -07:00
|
|
|
| ___________^
|
2017-04-13 22:37:05 +03:00
|
|
|
21 | | Z = { 2 + 3 };
|
2017-04-14 16:38:10 -07:00
|
|
|
| |____^ missing `fn`, `type`, or `const`
|
2017-04-13 22:37:05 +03:00
|
|
|
|
|
|
|
error: expected one of `const`, `extern`, `fn`, `type`, `unsafe`, or `}`, found `;`
|
|
|
|
--> $DIR/issue-40006.rs:21:18
|
|
|
|
|
|
|
|
|
21 | Z = { 2 + 3 };
|
|
|
|
| ^ expected one of `const`, `extern`, `fn`, `type`, `unsafe`, or `}` here
|
|
|
|
|
|
|
|
error: expected one of `!` or `::`, found `(`
|
|
|
|
--> $DIR/issue-40006.rs:22:9
|
|
|
|
|
|
|
|
|
22 | ::Y ();
|
|
|
|
| -^ unexpected token
|
|
|
|
| |
|
|
|
|
| expected one of `!` or `::` here
|
|
|
|
|
|
|
|
error: missing `fn`, `type`, or `const` for impl-item declaration
|
|
|
|
--> $DIR/issue-40006.rs:26:8
|
|
|
|
|
|
|
|
|
26 | pub hello_method(&self) {
|
|
|
|
| ^ missing `fn`, `type`, or `const`
|
|
|
|
|
|
|
|
error[E0038]: the trait `X` cannot be made into an object
|
|
|
|
--> $DIR/issue-40006.rs:11:6
|
|
|
|
|
|
|
|
|
11 | impl X {
|
|
|
|
| ^ the trait `X` cannot be made into an object
|
|
|
|
|
|
|
|
|
= note: method `xxx` has no receiver
|
2017-03-24 23:00:21 -07:00
|
|
|
|
2017-07-02 13:49:30 +03:00
|
|
|
error: aborting due to previous error
|
2017-03-24 23:00:21 -07:00
|
|
|
|