summaryrefslogtreecommitdiffstats
path: root/tests/ui/generic-const-items/misplaced-where-clause.rs
blob: b14c6d594a5268b76f78c46dc38f647064f19201 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// run-rustfix

#![feature(generic_const_items)]
#![allow(incomplete_features, dead_code)]

const K<T>: u64
where
    T: Tr<()>
= T::K;
//~^^^ ERROR where clauses are not allowed before const item bodies

trait Tr<P> {
    const K: u64
    where
        P: Copy
    = 0;
    //~^^^ ERROR where clauses are not allowed before const item bodies
}

fn main() {}