summaryrefslogtreecommitdiffstats
path: root/src/test/ui/traits/alias/issue-72415-assoc-const-resolve.rs
blob: e49125d10249d635391f7b231862a285e24eb175 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// check-pass

#![feature(trait_alias)]

trait Bounded { const MAX: Self; }

impl Bounded for u32 {
    // This should correctly resolve to the associated const in the inherent impl of u32.
    const MAX: Self = u32::MAX;
}

trait Num = Bounded + Copy;

fn main() {}