#zig build-obj {
--name test -fno-emit-bin
-Mroot=test.zig
#}

#write test.zig {
export fn entry1() void {
    foo();
}

comptime {
    qux();
}

inline fn foo() void {
    _ = bar();
}

fn bar() type {
    qux();
    return u8;
}

fn qux() void {
    rt = 123;
}

var rt: u32 = undefined;
#}
#update
#check errors {
test.zig:19:8: error: unable to evaluate comptime expression
test.zig:19:5: note: operation is runtime due to this operand
test.zig:6:8: note: called at comptime from here
test.zig:5:1: note: 'comptime' keyword forces comptime evaluation
test.zig:19:8: error: unable to evaluate comptime expression
test.zig:19:5: note: operation is runtime due to this operand
test.zig:14:8: note: called at comptime from here
test.zig:10:12: note: called at comptime from here
test.zig:10:12: note: call to function with comptime-only return type 'type' is evaluated at comptime
test.zig:13:10: note: return type declared here
test.zig:10:12: note: types are not available at runtime
test.zig:2:8: note: called inline here
#}
