File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -93,6 +93,23 @@ mod bar {
9393```
9494"## ,
9595
96+ E0253 : r##"
97+ Attempt was made to import an unimportable value. This can happen when
98+ trying to import a method from a trait. An example of this error:
99+
100+ ```
101+ mod foo {
102+ pub trait MyTrait {
103+ fn do_something();
104+ }
105+ }
106+ use foo::MyTrait::do_something;
107+ ```
108+
109+ In general, it's not legal to directly import methods belonging to a
110+ trait or concrete type.
111+ "## ,
112+
96113E0255 : r##"
97114You can't import a value whose name is the same as another value defined in the
98115module.
@@ -262,7 +279,6 @@ http://doc.rust-lang.org/reference.html#use-declarations
262279register_diagnostics ! {
263280 E0153 , // called no where
264281 E0157 , // called from no where
265- E0253 , // not directly importable
266282 E0254 , // import conflicts with imported crate in this module
267283 E0257 ,
268284 E0258 ,
You can’t perform that action at this time.
0 commit comments