about summary refs log tree commit diff
path: root/tests/ui/generic-const-items/hkl_where_bounds.rs
blob: cded518312a0511b9052402bfdbb063e8eace1cb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
//! Test that nonsense bounds prevent consts from being evaluated at all.
//@ check-pass

#![feature(generic_const_items)]
#![allow(incomplete_features)]
trait Trait {
    const ASSOC: u32;
}

// rustfmt eats the where bound
#[rustfmt::skip]
const ASSOC: u32 = <&'static ()>::ASSOC where for<'a> &'a (): Trait;

fn main() {}