about summary refs log tree commit diff
path: root/tests/ui/impl-trait
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/impl-trait')
-rw-r--r--tests/ui/impl-trait/issues/issue-78722-2.stderr18
-rw-r--r--tests/ui/impl-trait/issues/issue-86800.rs4
-rw-r--r--tests/ui/impl-trait/issues/issue-86800.stderr13
3 files changed, 22 insertions, 13 deletions
diff --git a/tests/ui/impl-trait/issues/issue-78722-2.stderr b/tests/ui/impl-trait/issues/issue-78722-2.stderr
index 8817eb7d243..69c734530f2 100644
--- a/tests/ui/impl-trait/issues/issue-78722-2.stderr
+++ b/tests/ui/impl-trait/issues/issue-78722-2.stderr
@@ -1,12 +1,3 @@
-error[E0658]: `async` blocks are not allowed in constants
-  --> $DIR/issue-78722-2.rs:15:20
-   |
-LL |         let f: F = async { 1 };
-   |                    ^^^^^^^^^^^
-   |
-   = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
-   = help: add `#![feature(const_async_blocks)]` to the crate attributes to enable
-
 error[E0271]: expected `{async block@$DIR/issue-78722-2.rs:13:13: 13:21}` to be a future that resolves to `u8`, but it resolves to `()`
   --> $DIR/issue-78722-2.rs:11:30
    |
@@ -26,6 +17,15 @@ note: this item must mention the opaque type in its signature in order to be abl
 LL |         let f: F = async { 1 };
    |                    ^^^^^^^^^^^
 
+error[E0658]: `async` blocks are not allowed in constants
+  --> $DIR/issue-78722-2.rs:15:20
+   |
+LL |         let f: F = async { 1 };
+   |                    ^^^^^^^^^^^
+   |
+   = note: see issue #85368 <https://github.com/rust-lang/rust/issues/85368> for more information
+   = help: add `#![feature(const_async_blocks)]` to the crate attributes to enable
+
 error: aborting due to 3 previous errors
 
 Some errors have detailed explanations: E0271, E0658.
diff --git a/tests/ui/impl-trait/issues/issue-86800.rs b/tests/ui/impl-trait/issues/issue-86800.rs
index df70b324c5e..297b012d90a 100644
--- a/tests/ui/impl-trait/issues/issue-86800.rs
+++ b/tests/ui/impl-trait/issues/issue-86800.rs
@@ -1,8 +1,8 @@
 #![feature(type_alias_impl_trait)]
 
 // edition:2021
-// compile-flags:-Z treat-err-as-bug=1
-// error-pattern: aborting due to `-Z treat-err-as-bug=1`
+// compile-flags:-Z treat-err-as-bug=2
+// error-pattern: due to `-Z treat-err-as-bug=2
 // failure-status:101
 // normalize-stderr-test ".*note: .*\n\n" -> ""
 // normalize-stderr-test "thread 'rustc' panicked.*:\n.*\n" -> ""
diff --git a/tests/ui/impl-trait/issues/issue-86800.stderr b/tests/ui/impl-trait/issues/issue-86800.stderr
index 8228f8ace9d..07ba8eb021b 100644
--- a/tests/ui/impl-trait/issues/issue-86800.stderr
+++ b/tests/ui/impl-trait/issues/issue-86800.stderr
@@ -4,9 +4,18 @@ error: unconstrained opaque type
 LL | type TransactionFuture<'__, O> = impl '__ + Future<Output = TransactionResult<O>>;
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
+error[E0792]: expected generic lifetime parameter, found `'_`
+  --> $DIR/issue-86800.rs:39:5
+   |
+LL | type TransactionFuture<'__, O> = impl '__ + Future<Output = TransactionResult<O>>;
+   |                        --- this generic parameter must be used with a generic lifetime parameter
+...
+LL |     f
+   |     ^
+
 error: the compiler unexpectedly panicked. this is a bug.
 
 query stack during panic:
-#0 [type_of_opaque] computing type of opaque `TransactionFuture::{opaque#0}`
-#1 [type_of] computing type of `TransactionFuture::{opaque#0}`
+#0 [mir_borrowck] borrow-checking `execute_transaction_fut`
+#1 [type_of_opaque] computing type of opaque `execute_transaction_fut::{opaque#0}`
 end of query stack