about summary refs log tree commit diff
path: root/tests/ui/const-generics/adt_const_params/non_valtreeable_const_arg-1.rs
blob: cea82722a0e6080192b60d32f8cf37309c4163d7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
#![feature(generic_const_exprs)]
#![allow(incomplete_features)]

// Regression test for #118545

struct Checked<const F: fn()>;
//~^ ERROR: using function pointers as const generic parameters is forbidden

fn foo() {}
const _: Checked<foo> = Checked::<foo>;

pub fn main() {}