diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2025-02-22 17:03:24 -0800 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2025-02-22 17:09:20 -0800 |
| commit | eb3c7f570601a6e00cbf03f0a026b3493887a534 (patch) | |
| tree | e621eb6aa4ab49bb72018d33c373b258f55922df /src/Sema.zig | |
| parent | c0c911bfa78ea2968cd110ad64a4ba0d70ca93e5 (diff) | |
| download | zig-eb3c7f570601a6e00cbf03f0a026b3493887a534.tar.gz zig-eb3c7f570601a6e00cbf03f0a026b3493887a534.zip | |
zig build fmt
Diffstat (limited to 'src/Sema.zig')
| -rw-r--r-- | src/Sema.zig | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/Sema.zig b/src/Sema.zig index 7e3ab51a29..ea51589911 100644 --- a/src/Sema.zig +++ b/src/Sema.zig @@ -23443,7 +23443,7 @@ fn ptrCastFull( errdefer msg.destroy(sema.gpa); if (dest_info.flags.size == .many and (src_info.flags.size == .slice or - (src_info.flags.size == .one and Type.fromInterned(src_info.child).zigTypeTag(zcu) == .array))) + (src_info.flags.size == .one and Type.fromInterned(src_info.child).zigTypeTag(zcu) == .array))) { try sema.errNote(src, msg, "use 'ptr' field to convert slice to many pointer", .{}); } else { @@ -28136,9 +28136,9 @@ fn fieldCallBind( const first_param_type = Type.fromInterned(func_type.param_types.get(ip)[0]); if (first_param_type.isGenericPoison() or (first_param_type.zigTypeTag(zcu) == .pointer and - (first_param_type.ptrSize(zcu) == .one or - first_param_type.ptrSize(zcu) == .c) and - first_param_type.childType(zcu).eql(concrete_ty, zcu))) + (first_param_type.ptrSize(zcu) == .one or + first_param_type.ptrSize(zcu) == .c) and + first_param_type.childType(zcu).eql(concrete_ty, zcu))) { // Note that if the param type is generic poison, we know that it must // specifically be `anytype` since it's the first parameter, meaning we @@ -29652,7 +29652,7 @@ fn coerceExtra( if (dest_info.sentinel == .none or inst_info.sentinel == .none or Air.internedToRef(dest_info.sentinel) != - try sema.coerceInMemory(Value.fromInterned(inst_info.sentinel), Type.fromInterned(dest_info.child))) + try sema.coerceInMemory(Value.fromInterned(inst_info.sentinel), Type.fromInterned(dest_info.child))) break :p; const slice_ptr = try sema.analyzeSlicePtr(block, inst_src, inst, inst_ty); @@ -30492,12 +30492,12 @@ pub fn coerceInMemoryAllowed( } const ok_sent = (dest_info.sentinel == null and src_info.sentinel == null) or (src_info.sentinel != null and - dest_info.sentinel != null and - dest_info.sentinel.?.eql( - try pt.getCoerced(src_info.sentinel.?, dest_info.elem_type), - dest_info.elem_type, - zcu, - )); + dest_info.sentinel != null and + dest_info.sentinel.?.eql( + try pt.getCoerced(src_info.sentinel.?, dest_info.elem_type), + dest_info.elem_type, + zcu, + )); if (!ok_sent) { return .{ .array_sentinel = .{ .actual = src_info.sentinel orelse Value.@"unreachable", |
