about summary refs log tree commit diff
path: root/src/test/ui/const-generics/foreign-item-const-parameter.rs
blob: 44b6d0332c3f9026bb7ff65c8f382124bab60a58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// revisions: full min

#![cfg_attr(full, feature(const_generics))]
#![cfg_attr(full, allow(incomplete_features))]
#![cfg_attr(min, feature(min_const_generics))]

extern "C" {
    fn foo<const X: usize>(); //~ ERROR foreign items may not have const parameters

    fn bar<T, const X: usize>(_: T); //~ ERROR foreign items may not have type or const parameters
}

fn main() {}