rust/tests/ui/const-generics/auxiliary/legacy-const-generics.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

7 lines
139 B
Rust
Raw Normal View History

2021-02-23 09:12:28 -06:00
#![feature(rustc_attrs)]
#[rustc_legacy_const_generics(1)]
pub fn foo<const Y: usize>(x: usize, z: usize) -> [usize; 3] {
[x, Y, z]
}