]> git.lizzy.rs Git - rust.git/blob - src/test/ui/type-alias-impl-trait/different_defining_uses.rs
Loop over all opaque types instead of looking at just the first one with the same...
[rust.git] / src / test / ui / type-alias-impl-trait / different_defining_uses.rs
1 // revisions: min_tait full_tait
2 #![feature(min_type_alias_impl_trait)]
3 #![cfg_attr(full_tait, feature(type_alias_impl_trait))]
4 //[full_tait]~^ WARN incomplete
5
6 fn main() {}
7
8 // two definitions with different types
9 type Foo = impl std::fmt::Debug;
10
11 fn foo() -> Foo {
12     ""
13 }
14
15 fn bar() -> Foo { //~ ERROR concrete type differs from previous
16     42i32
17 }