rust/tests/ui/const-generics/issues/issue-99641.rs
2023-01-11 09:32:08 +00:00

19 lines
389 B
Rust

#![feature(adt_const_params)]
#![allow(incomplete_features)]
fn main() {
pub struct Color<const WHITE: (fn(),)>;
//~^ ERROR using function pointers
impl<const WHITE: (fn(),)> Color<WHITE> {
//~^ ERROR using function pointers
pub fn new() -> Self {
Color::<WHITE>
}
}
pub const D65: (fn(),) = (|| {},);
Color::<D65>::new();
}