Regression test for #58813
(Update: Fixed test; revision is meant to introduce compile-failure, w/o ICE.)
This commit is contained in:
parent
a9da8fc9c2
commit
c0767012d5
1 changed files with 14 additions and 0 deletions
14
src/test/incremental/cyclic-trait-hierarchy.rs
Normal file
14
src/test/incremental/cyclic-trait-hierarchy.rs
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
// Adapated from rust-lang/rust#58813
|
||||
|
||||
// revisions: rpass1 cfail2
|
||||
|
||||
#[cfg(rpass1)]
|
||||
pub trait T2 { }
|
||||
#[cfg(cfail2)]
|
||||
pub trait T2: T1 { }
|
||||
//[cfail2]~^ ERROR cycle detected when computing the supertraits of `T2`
|
||||
//[cfail2]~| ERROR cycle detected when computing the supertraits of `T2`
|
||||
|
||||
pub trait T1: T2 { }
|
||||
|
||||
fn main() { }
|
||||
Loading…
Add table
Add a link
Reference in a new issue