aboutsummaryrefslogtreecommitdiff
path: root/src/AstGen.zig
diff options
context:
space:
mode:
authormlugg <mlugg@mlugg.co.uk>2023-08-27 17:03:42 +0100
committerAndrew Kelley <andrew@ziglang.org>2023-08-28 12:32:02 -0700
commit8d036d1d78bd6db5fd39b30c6182196c1e49a3db (patch)
treeae65a34daabcc80a7b1faf04918fd8fb9ead2565 /src/AstGen.zig
parentc6024691cfc3fa329cf1b7ac9fcb0855b7211aa0 (diff)
downloadzig-8d036d1d78bd6db5fd39b30c6182196c1e49a3db.tar.gz
zig-8d036d1d78bd6db5fd39b30c6182196c1e49a3db.zip
Sema: allow cast builtins on vectors
The following cast builtins did not previously work on vectors, and have been made to: * `@floatCast` * `@ptrFromInt` * `@intFromPtr` * `@floatFromInt` * `@intFromFloat` * `@intFromBool` Resolves: #16267
Diffstat (limited to 'src/AstGen.zig')
-rw-r--r--src/AstGen.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/AstGen.zig b/src/AstGen.zig
index 0116e00f8b..80f7017ecc 100644
--- a/src/AstGen.zig
+++ b/src/AstGen.zig
@@ -8041,7 +8041,7 @@ fn builtinCall(
.compile_error => return simpleUnOp(gz, scope, ri, node, .{ .rl = .{ .ty = .slice_const_u8_type } }, params[0], .compile_error),
.set_eval_branch_quota => return simpleUnOp(gz, scope, ri, node, .{ .rl = .{ .coerced_ty = .u32_type } }, params[0], .set_eval_branch_quota),
.int_from_enum => return simpleUnOp(gz, scope, ri, node, .{ .rl = .none }, params[0], .int_from_enum),
- .int_from_bool => return simpleUnOp(gz, scope, ri, node, bool_ri, params[0], .int_from_bool),
+ .int_from_bool => return simpleUnOp(gz, scope, ri, node, .{ .rl = .none }, params[0], .int_from_bool),
.embed_file => return simpleUnOp(gz, scope, ri, node, .{ .rl = .{ .ty = .slice_const_u8_type } }, params[0], .embed_file),
.error_name => return simpleUnOp(gz, scope, ri, node, .{ .rl = .{ .ty = .anyerror_type } }, params[0], .error_name),
.set_runtime_safety => return simpleUnOp(gz, scope, ri, node, bool_ri, params[0], .set_runtime_safety),