2022-07-23 15:09:52 -05:00
|
|
|
#![feature(adt_const_params)]
|
|
|
|
#![allow(incomplete_features)]
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
pub struct Color<const WHITE: (fn(),)>;
|
2023-05-16 23:05:46 -05:00
|
|
|
//~^ ERROR `(fn(),)` can't be used as a const parameter type
|
2022-07-23 15:09:52 -05:00
|
|
|
|
|
|
|
impl<const WHITE: (fn(),)> Color<WHITE> {
|
2023-05-16 23:05:46 -05:00
|
|
|
//~^ ERROR `(fn(),)` can't be used as a const parameter type
|
2022-07-23 15:09:52 -05:00
|
|
|
pub fn new() -> Self {
|
|
|
|
Color::<WHITE>
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
pub const D65: (fn(),) = (|| {},);
|
|
|
|
|
|
|
|
Color::<D65>::new();
|
|
|
|
}
|