Skip to content

Commit c886379

Browse files
authored
Unrolled build for rust-lang#130276
Rollup merge of rust-lang#130276 - compiler-errors:nalgebra-hang, r=lcnr Add test for nalgebra hang in coherence r? lcnr
2 parents 8c0ec05 + d3ebd23 commit c886379

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
//@ check-pass
2+
3+
// Regression test for nalgebra hang <https://github.com/rust-lang/rust/issues/130056>.
4+
5+
#![feature(lazy_type_alias)]
6+
#![allow(incomplete_features)]
7+
8+
type Id<T: ?Sized> = T;
9+
trait NotImplemented {}
10+
11+
struct W<T: ?Sized, U: ?Sized>(*const T, *const U);
12+
trait Trait {
13+
type Assoc: ?Sized;
14+
}
15+
impl<T: ?Sized + Trait> Trait for W<T, T> {
16+
type Assoc = W<T::Assoc, Id<T::Assoc>>;
17+
}
18+
19+
trait Overlap<T: ?Sized> {}
20+
impl<T: ?Sized> Overlap<T> for W<T, T> {}
21+
impl<T: ?Sized + Trait + NotImplemented> Overlap<T::Assoc> for T {}
22+
23+
fn main() {}

0 commit comments

Comments
 (0)