blob: 2f3b5c5dc5b899bd034f87d307a9e3a9f9d2f0a2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
// run-pass
#![feature(const_generics)]
//~^ WARN the feature `const_generics` is incomplete
pub trait BitLen: Sized {
const BIT_LEN: usize;
}
impl<const L: usize> BitLen for [u8; L] {
const BIT_LEN: usize = 8 * L;
}
fn main() {
let foo = <[u8; 2]>::BIT_LEN; //~ WARN unused variable
}
|