2018-11-30 08:43:50 +01:00
|
|
|
const fn foo() { (||{})() }
|
2022-09-21 15:02:15 +00:00
|
|
|
//~^ ERROR cannot call non-const closure
|
2018-11-30 08:43:50 +01:00
|
|
|
|
|
|
|
const fn bad(input: fn()) {
|
|
|
|
input()
|
2022-09-21 15:02:15 +00:00
|
|
|
//~^ ERROR function pointer calls are not allowed
|
2018-11-30 08:43:50 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
}
|