Closed
Description
This compiles:
mod foo {
trait IntoIterator {}
fn f() { Some(0).into_iter(); }
}
but this doesn't:
trait T {}
mod bar {
use T as IntoIterator;
fn f() { Some(0).into_iter(); }
}
More generally, a shadowed trait's methods are usable if it is shadowed by an item, but not if it is shadowed by an import.
Should methods from shadowed traits be usable?