2019-11-03 18:00:00 -06:00
|
|
|
// check-pass
|
2018-09-25 16:51:35 -05:00
|
|
|
#![allow(dead_code)]
|
2018-08-31 08:02:01 -05:00
|
|
|
#![allow(non_upper_case_globals)]
|
|
|
|
|
2015-10-24 16:29:13 -05:00
|
|
|
|
|
|
|
trait HasNumber<T> {
|
|
|
|
const Number: usize;
|
|
|
|
}
|
|
|
|
|
|
|
|
enum One {}
|
|
|
|
enum Two {}
|
|
|
|
|
|
|
|
enum Foo {}
|
|
|
|
|
|
|
|
impl<T> HasNumber<T> for One {
|
|
|
|
const Number: usize = 1;
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<T> HasNumber<T> for Two {
|
|
|
|
const Number: usize = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|