summaryrefslogtreecommitdiffstats
path: root/tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs')
-rw-r--r--tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs b/tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs
new file mode 100644
index 000000000..db5f6fe38
--- /dev/null
+++ b/tests/ui/associated-type-bounds/return-type-notation/non-rpitit.rs
@@ -0,0 +1,11 @@
+#![feature(return_type_notation)]
+//~^ WARN the feature `return_type_notation` is incomplete
+
+trait Trait {
+ fn method() {}
+}
+
+fn test<T: Trait<method(): Send>>() {}
+//~^ ERROR return type notation used on function that is not `async` and does not return `impl Trait`
+
+fn main() {}