summaryrefslogtreecommitdiffstats
path: root/tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-30 03:57:31 +0000
commitdc0db358abe19481e475e10c32149b53370f1a1c (patch)
treeab8ce99c4b255ce46f99ef402c27916055b899ee /tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr
parentReleasing progress-linux version 1.71.1+dfsg1-2~progress7.99u1. (diff)
downloadrustc-dc0db358abe19481e475e10c32149b53370f1a1c.tar.xz
rustc-dc0db358abe19481e475e10c32149b53370f1a1c.zip
Merging upstream version 1.72.1+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr')
-rw-r--r--tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr29
1 files changed, 29 insertions, 0 deletions
diff --git a/tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr b/tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr
new file mode 100644
index 000000000..1aa008fe4
--- /dev/null
+++ b/tests/ui/async-await/return-type-notation/ty-or-ct-params.current.stderr
@@ -0,0 +1,29 @@
+warning: the feature `return_type_notation` is incomplete and may not be safe to use and/or cause compiler crashes
+ --> $DIR/ty-or-ct-params.rs:5:31
+ |
+LL | #![feature(async_fn_in_trait, return_type_notation)]
+ | ^^^^^^^^^^^^^^^^^^^^
+ |
+ = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
+ = note: `#[warn(incomplete_features)]` on by default
+
+error: return type notation is not allowed for functions that have type parameters
+ --> $DIR/ty-or-ct-params.rs:16:12
+ |
+LL | async fn bar<T>() {}
+ | - type parameter declared here
+...
+LL | T: Foo<bar(): Send, baz(): Send>,
+ | ^^^^^^^^^^^
+
+error: return type notation is not allowed for functions that have const parameters
+ --> $DIR/ty-or-ct-params.rs:16:25
+ |
+LL | async fn baz<const N: usize>() {}
+ | -------------- const parameter declared here
+...
+LL | T: Foo<bar(): Send, baz(): Send>,
+ | ^^^^^^^^^^^
+
+error: aborting due to 2 previous errors; 1 warning emitted
+