test that fudging with opaque types is the same in the new solver
This commit is contained in:
parent
ef324565d0
commit
c86974d94f
@ -1,5 +1,5 @@
|
||||
error[E0282]: type annotations needed
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:8:17
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:10:17
|
||||
|
|
||||
LL | Thunk::new(|mut cont| {
|
||||
| ^^^^^^^^
|
||||
@ -13,7 +13,7 @@ LL | Thunk::new(|mut cont: /* Type */| {
|
||||
| ++++++++++++
|
||||
|
||||
error[E0282]: type annotations needed
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:18:17
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:20:17
|
||||
|
|
||||
LL | Thunk::new(|mut cont| {
|
||||
| ^^^^^^^^
|
31
tests/ui/impl-trait/hidden-type-is-opaque-2.next.stderr
Normal file
31
tests/ui/impl-trait/hidden-type-is-opaque-2.next.stderr
Normal file
@ -0,0 +1,31 @@
|
||||
error[E0282]: type annotations needed
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:10:17
|
||||
|
|
||||
LL | Thunk::new(|mut cont| {
|
||||
| ^^^^^^^^
|
||||
LL |
|
||||
LL | cont.reify_as();
|
||||
| ---- type must be known at this point
|
||||
|
|
||||
help: consider giving this closure parameter an explicit type
|
||||
|
|
||||
LL | Thunk::new(|mut cont: /* Type */| {
|
||||
| ++++++++++++
|
||||
|
||||
error[E0282]: type annotations needed
|
||||
--> $DIR/hidden-type-is-opaque-2.rs:20:17
|
||||
|
|
||||
LL | Thunk::new(|mut cont| {
|
||||
| ^^^^^^^^
|
||||
LL |
|
||||
LL | cont.reify_as();
|
||||
| ---- type must be known at this point
|
||||
|
|
||||
help: consider giving this closure parameter an explicit type
|
||||
|
|
||||
LL | Thunk::new(|mut cont: /* Type */| {
|
||||
| ++++++++++++
|
||||
|
||||
error: aborting due to 2 previous errors
|
||||
|
||||
For more information about this error, try `rustc --explain E0282`.
|
@ -1,6 +1,8 @@
|
||||
// This doesn't work, because we don't flow information from opaque types
|
||||
// into function arguments via the function's generic parameters
|
||||
// FIXME(oli-obk): make `expected_inputs_for_expected_output` support this
|
||||
//@ revisions: default next
|
||||
//@[next] compile-flags: -Znext-solver
|
||||
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user