mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 00:03:43 +00:00
16 lines
264 B
Rust
16 lines
264 B
Rust
// Check for recursion involving references to impl-associated const.
|
|
|
|
trait Foo {
|
|
const BAR: u32;
|
|
}
|
|
|
|
const IMPL_REF_BAR: u32 = GlobalImplRef::BAR;
|
|
|
|
struct GlobalImplRef;
|
|
|
|
impl GlobalImplRef {
|
|
const BAR: u32 = IMPL_REF_BAR; //~ ERROR E0391
|
|
}
|
|
|
|
fn main() {}
|