Sign in
android
/
toolchain
/
rustc
/
refs/heads/main
/
.
/
tests
/
ui
/
const-generics
/
issues
/
issue-62187-encountered-polymorphic-const.rs
blob: 778e4a31d15f6c703d07b4e03521107d7128fc0b [
file
] [
log
] [
blame
]
//@ run-pass
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
;
}