diff options
| author | Felix S. Klock II <pnkfelix@pnkfx.org> | 2019-03-04 13:55:32 +0100 |
|---|---|---|
| committer | Felix S. Klock II <pnkfelix@pnkfx.org> | 2019-03-06 12:36:47 +0100 |
| commit | c0767012d5658a1b88fa4bbdce56ac2ea2dd78e0 (patch) | |
| tree | 7d470dc73da2b5b5081371729e1ef34caae215d7 /src | |
| parent | a9da8fc9c267c08cfdb8cf5b39da14f154d12939 (diff) | |
| download | rust-c0767012d5658a1b88fa4bbdce56ac2ea2dd78e0.tar.gz rust-c0767012d5658a1b88fa4bbdce56ac2ea2dd78e0.zip | |
Regression test for #58813
(Update: Fixed test; revision is meant to introduce compile-failure, w/o ICE.)
Diffstat (limited to 'src')
| -rw-r--r-- | src/test/incremental/cyclic-trait-hierarchy.rs | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/incremental/cyclic-trait-hierarchy.rs b/src/test/incremental/cyclic-trait-hierarchy.rs new file mode 100644 index 00000000000..4102eb32580 --- /dev/null +++ b/src/test/incremental/cyclic-trait-hierarchy.rs @@ -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() { } |
