You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
mod rustfmt {pubfnskip(){}}use rustfmt::skip;fnmain(){skip()}
I expected to see this happen: No error, as the rustfmt tool module cannot be imported from, so the path should resolve to the module.
Instead, this happened:
error[E0659]: `rustfmt` is ambiguous
--> poc.rs:3:5
|
3 | use rustfmt::skip;
| ^^^^^^^ ambiguous name
|
= note: ambiguous because of multiple potential import sources
= note: `rustfmt` could refer to a tool module
note: `rustfmt` could also refer to the module defined here
--> poc.rs:1:1
|
1 | mod rustfmt { pub fn skip() {} }
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= help: use `crate::rustfmt` to refer to this module unambiguously
This would make adding new tool namespaces (such as the proposed RFC 3368 a breaking change.
I tried this code:
I expected to see this happen: No error, as the
rustfmt
tool module cannot be imported from, so the path should resolve to the module.Instead, this happened:
This would make adding new tool namespaces (such as the proposed RFC 3368 a breaking change.
Meta
Present on stable, nightly and master.
@rustbot label +A-resolve
The text was updated successfully, but these errors were encountered: