aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/comptime_call_of_function_pointer.zig
blob: a73f541b5ea37e2d3ce278d007586f6c21873f75 (plain)
1
2
3
4
5
6
7
8
9
export fn entry() void {
    const fn_ptr: *align(1) fn () void = @ptrFromInt(0xffd2);
    comptime fn_ptr();
}

// error
//
// :3:14: error: unable to resolve comptime value
// :3:14: note: function being called at comptime must be comptime-known