mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 16:24:46 +00:00
Fix invalid compiletest directives in tests
- Fix invalid directive in `normalize-hidden-types` - Update legacy directive in `two-phase-reservation-sharing-interference`
This commit is contained in:
parent
5877e7e8d2
commit
64dda8c837
@ -2,7 +2,7 @@
|
||||
|
||||
// The nll_beyond revision is disabled due to missing support from two-phase beyond autorefs
|
||||
//@[nll_beyond]compile-flags: -Z two-phase-beyond-autoref
|
||||
//[nll_beyond]should-fail
|
||||
//@[nll_beyond]should-fail
|
||||
|
||||
// This is a corner case that the current implementation is (probably)
|
||||
// treating more conservatively than is necessary. But it also does
|
||||
|
@ -5,25 +5,25 @@ LL | fn define() -> Opaque {
|
||||
| ^^^^^^ expected `*const (dyn FnOnce(()) + 'static)`, got `*const dyn for<'a> FnOnce(<u8 as Trait>::Gat<'a>)`
|
||||
|
|
||||
note: previous use here
|
||||
--> $DIR/normalize-hidden-types.rs:27:9
|
||||
--> $DIR/normalize-hidden-types.rs:26:9
|
||||
|
|
||||
LL | dyn_hoops::<_>(0)
|
||||
| ^^^^^^^^^^^^^^^^^
|
||||
|
||||
error: concrete type differs from previous defining opaque type use
|
||||
--> $DIR/normalize-hidden-types.rs:34:22
|
||||
--> $DIR/normalize-hidden-types.rs:33:22
|
||||
|
|
||||
LL | fn define_1() -> Opaque { dyn_hoops::<_>(0) }
|
||||
| ^^^^^^ expected `*const (dyn FnOnce(()) + 'static)`, got `*const dyn for<'a> FnOnce(<u8 as Trait>::Gat<'a>)`
|
||||
|
|
||||
note: previous use here
|
||||
--> $DIR/normalize-hidden-types.rs:34:31
|
||||
--> $DIR/normalize-hidden-types.rs:33:31
|
||||
|
|
||||
LL | fn define_1() -> Opaque { dyn_hoops::<_>(0) }
|
||||
| ^^^^^^^^^^^^^^^^^
|
||||
|
||||
error[E0308]: mismatched types
|
||||
--> $DIR/normalize-hidden-types.rs:44:25
|
||||
--> $DIR/normalize-hidden-types.rs:42:25
|
||||
|
|
||||
LL | type Opaque = impl Sized;
|
||||
| ---------- the expected opaque type
|
||||
@ -39,13 +39,13 @@ LL | let _: Opaque = dyn_hoops::<u8>(0);
|
||||
= note: for more information, visit https://doc.rust-lang.org/book/ch19-03-advanced-traits.html
|
||||
|
||||
error: concrete type differs from previous defining opaque type use
|
||||
--> $DIR/normalize-hidden-types.rs:54:25
|
||||
--> $DIR/normalize-hidden-types.rs:51:25
|
||||
|
|
||||
LL | let _: Opaque = dyn_hoops::<_>(0);
|
||||
| ^^^^^^^^^^^^^^^^^ expected `*const (dyn FnOnce(()) + 'static)`, got `*const dyn for<'a> FnOnce(<u8 as Trait>::Gat<'a>)`
|
||||
|
|
||||
note: previous use here
|
||||
--> $DIR/normalize-hidden-types.rs:56:9
|
||||
--> $DIR/normalize-hidden-types.rs:52:9
|
||||
|
|
||||
LL | None
|
||||
| ^^^^
|
||||
|
@ -3,7 +3,7 @@
|
||||
//@ revisions: current next
|
||||
//@ [next] compile-flags: -Znext-solver
|
||||
//@ [next] check-pass
|
||||
//@ [current]: known-bug: #112691
|
||||
//@ [current] known-bug: #112691
|
||||
|
||||
#![feature(type_alias_impl_trait)]
|
||||
|
||||
@ -23,7 +23,6 @@ mod typeof_1 {
|
||||
use super::*;
|
||||
type Opaque = impl Sized;
|
||||
fn define() -> Opaque {
|
||||
//[current]~^ ERROR concrete type differs
|
||||
dyn_hoops::<_>(0)
|
||||
}
|
||||
}
|
||||
@ -32,7 +31,6 @@ mod typeof_2 {
|
||||
use super::*;
|
||||
type Opaque = impl Sized;
|
||||
fn define_1() -> Opaque { dyn_hoops::<_>(0) }
|
||||
//[current]~^ ERROR concrete type differs
|
||||
fn define_2() -> Opaque { dyn_hoops::<u8>(0) }
|
||||
}
|
||||
|
||||
@ -42,7 +40,6 @@ mod typeck {
|
||||
fn define() -> Option<Opaque> {
|
||||
let _: Opaque = dyn_hoops::<_>(0);
|
||||
let _: Opaque = dyn_hoops::<u8>(0);
|
||||
//[current]~^ ERROR mismatched types
|
||||
None
|
||||
}
|
||||
}
|
||||
@ -52,7 +49,6 @@ mod borrowck {
|
||||
type Opaque = impl Sized;
|
||||
fn define() -> Option<Opaque> {
|
||||
let _: Opaque = dyn_hoops::<_>(0);
|
||||
//[current]~^ ERROR concrete type differs
|
||||
None
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user