This is broken. It typechecks when it shouldn't and (unsurprisingly) crashes during llvmgen
func g(i32_t x) -> i32_t { return 1; }
func h((0 i32_t) -> i32_t f, i32_t x) -> i32_t { return f(x); }
func test() -> i32_t { return h(g, 0); }
This works and emits correct LLVM.
func g(0 i32_t x) -> i32_t { return 1; }
func h((0 i32_t) -> i32_t f, i32_t x) -> i32_t { return f(x); }
func test() -> i32_t { return h(g, 0); }