summaryrefslogtreecommitdiffstats
path: root/tests/ui/impl-trait/nested-return-type2-tait3.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/impl-trait/nested-return-type2-tait3.rs')
-rw-r--r--tests/ui/impl-trait/nested-return-type2-tait3.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/ui/impl-trait/nested-return-type2-tait3.rs b/tests/ui/impl-trait/nested-return-type2-tait3.rs
index 74fd8a9dd..eed5c271f 100644
--- a/tests/ui/impl-trait/nested-return-type2-tait3.rs
+++ b/tests/ui/impl-trait/nested-return-type2-tait3.rs
@@ -1,3 +1,5 @@
+// check-pass
+
#![feature(type_alias_impl_trait)]
trait Duh {}
@@ -16,6 +18,7 @@ impl<R: Duh, F: FnMut() -> R> Trait for F {
}
type Traitable = impl Trait<Assoc = impl Send>;
+//~^ WARN opaque type `Traitable` does not satisfy its associated type bounds
// The `impl Send` here is then later compared against the inference var
// created, causing the inference var to be set to `impl Send` instead of
@@ -24,7 +27,6 @@ type Traitable = impl Trait<Assoc = impl Send>;
// type does not implement `Duh`, even if its hidden type does. So we error out.
fn foo() -> Traitable {
|| 42
- //~^ ERROR `impl Send: Duh` is not satisfied
}
fn main() {