mirror of
https://github.com/ziglang/zig.git
synced 2024-11-26 23:22:44 +00:00
parent
b483c796c6
commit
5831b68341
@ -9098,6 +9098,8 @@ fn nodeMayNeedMemoryLocation(tree: *const Ast, start_node: Ast.Node.Index, have_
|
||||
.always => return true,
|
||||
.forward1 => node = node_datas[node].rhs,
|
||||
}
|
||||
// Missing builtin arg is not a parsing error, expect an error later.
|
||||
if (node == 0) return false;
|
||||
},
|
||||
|
||||
.builtin_call, .builtin_call_comma => {
|
||||
@ -9112,6 +9114,8 @@ fn nodeMayNeedMemoryLocation(tree: *const Ast, start_node: Ast.Node.Index, have_
|
||||
.always => return true,
|
||||
.forward1 => node = params[1],
|
||||
}
|
||||
// Missing builtin arg is not a parsing error, expect an error later.
|
||||
if (node == 0) return false;
|
||||
},
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,13 @@
|
||||
comptime {
|
||||
const v = @as();
|
||||
}
|
||||
comptime {
|
||||
const u = @bitCast(u32);
|
||||
}
|
||||
|
||||
// error
|
||||
// backend=stage2
|
||||
// target=native
|
||||
//
|
||||
// :2:15: error: expected 2 arguments, found 0
|
||||
// :5:15: error: expected 2 arguments, found 1
|
Loading…
Reference in New Issue
Block a user