2019-10-15 00:20:50 +00:00
|
|
|
error[E0423]: expected function, tuple struct or tuple variant, found trait `Bar`
|
2018-12-25 15:56:47 +00:00
|
|
|
--> $DIR/privacy-ns1.rs:20:5
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
2019-10-15 00:20:50 +00:00
|
|
|
LL | pub struct Baz;
|
|
|
|
| --------------- similarly named unit struct `Baz` defined here
|
|
|
|
...
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Bar();
|
2019-01-09 19:11:00 +00:00
|
|
|
| ^^^
|
2019-10-24 05:20:58 +00:00
|
|
|
|
|
2019-01-09 19:11:00 +00:00
|
|
|
help: a unit struct with a similar name exists
|
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Baz();
|
2021-06-22 02:07:19 +00:00
|
|
|
| ~~~
|
2020-06-13 17:58:46 +00:00
|
|
|
help: consider importing this function instead
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
|
|
|
LL | use foo2::Bar;
|
|
|
|
|
|
|
|
|
|
2019-10-15 00:20:50 +00:00
|
|
|
error[E0425]: cannot find function, tuple struct or tuple variant `Bar` in this scope
|
2019-11-18 19:57:46 +00:00
|
|
|
--> $DIR/privacy-ns1.rs:51:5
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
2019-10-15 00:20:50 +00:00
|
|
|
LL | pub struct Baz;
|
|
|
|
| --------------- similarly named unit struct `Baz` defined here
|
|
|
|
...
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Bar();
|
2019-01-09 19:11:00 +00:00
|
|
|
| ^^^
|
2019-10-24 05:20:58 +00:00
|
|
|
|
|
2019-01-09 19:11:00 +00:00
|
|
|
help: a unit struct with a similar name exists
|
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | Baz();
|
2021-06-22 02:07:19 +00:00
|
|
|
| ~~~
|
2020-06-13 17:58:46 +00:00
|
|
|
help: consider importing this function
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
|
|
|
LL | use foo2::Bar;
|
|
|
|
|
|
|
|
|
|
|
|
|
error[E0412]: cannot find type `Bar` in this scope
|
2019-11-18 19:57:46 +00:00
|
|
|
--> $DIR/privacy-ns1.rs:52:17
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
2019-10-15 00:20:50 +00:00
|
|
|
LL | pub struct Baz;
|
|
|
|
| --------------- similarly named struct `Baz` defined here
|
|
|
|
...
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | let _x: Box<Bar>;
|
2019-01-09 19:11:00 +00:00
|
|
|
| ^^^
|
2019-10-24 05:20:58 +00:00
|
|
|
|
|
2019-01-09 19:11:00 +00:00
|
|
|
help: a struct with a similar name exists
|
|
|
|
|
|
2019-03-09 12:03:44 +00:00
|
|
|
LL | let _x: Box<Baz>;
|
2021-06-22 02:07:19 +00:00
|
|
|
| ~~~
|
2020-06-13 17:58:46 +00:00
|
|
|
help: consider importing this trait
|
2018-08-08 12:28:26 +00:00
|
|
|
|
|
|
|
|
LL | use foo1::Bar;
|
|
|
|
|
|
|
|
|
|
2020-11-13 19:23:37 +00:00
|
|
|
error[E0747]: constant provided when a type was expected
|
2019-11-18 19:57:46 +00:00
|
|
|
--> $DIR/privacy-ns1.rs:35:17
|
|
|
|
|
|
|
|
|
LL | let _x: Box<Bar>;
|
2020-11-13 19:23:37 +00:00
|
|
|
| ^^^
|
2021-04-24 14:25:36 +00:00
|
|
|
|
|
|
|
|
= help: `Bar` is a function item, not a type
|
|
|
|
= help: function item types cannot be named directly
|
2019-11-18 19:57:46 +00:00
|
|
|
|
2020-11-13 19:23:37 +00:00
|
|
|
error: aborting due to 4 previous errors
|
2018-08-08 12:28:26 +00:00
|
|
|
|
2020-11-13 19:23:37 +00:00
|
|
|
Some errors have detailed explanations: E0412, E0423, E0425, E0747.
|
|
|
|
For more information about an error, try `rustc --explain E0412`.
|