Sign in
android
/
toolchain
/
rustc
/
59fbe18bc79ed87d0c5f02705e7cf19e402e1f2b
/
.
/
src
/
test
/
ui
/
const-generics
/
const-arg-in-fn.rs
blob: 43ed12efb895a101f56b0337a0a18449ebeb1d86 [
file
] [
log
] [
blame
]
// run-pass
// revisions: full min
#![
cfg_attr
(
full
,
feature
(
const_generics
))]
#![
cfg_attr
(
full
,
allow
(
incomplete_features
))]
fn
const_u32_identity
<
const
X
:
u32
>()
->
u32
{
X
}
fn
main
()
{
let
val
=
const_u32_identity
::<
18
>();
assert_eq
!(
val
,
18
);
}