about summary refs log tree commit diff
path: root/tests/ui/associated-types/associated-type-shadowed-from-non-local-supertrait.rs
blob: 045a43548dcaa1768e3678d4867a7fda037919d5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// Test that no help message is emitted that suggests renaming the
// associated type from a non-local trait

pub trait NewIter: Iterator {
    type Item;
}

impl<T> Clone for Box<dyn NewIter<Item = T>> {
    //~^ ERROR the value of the associated type `Item` in `Iterator` must be specified
    fn clone(&self) -> Self {
        unimplemented!();
    }
}

pub fn main() {}