about summary refs log tree commit diff
path: root/tests/ui/associated-consts/assoc-const.rs
blob: 5b272cfeb0c28e5cdc91e6cbd390683d325d9e0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
//@ run-pass
#![feature(associated_const_equality)]
#![allow(unused)]

pub trait Foo {
  const N: usize;
}

pub struct Bar;

impl Foo for Bar {
  const N: usize = 3;
}

const TEST:usize = 3;


fn foo<F: Foo<N=3usize>>() {}

fn main() {
  foo::<Bar>()
}