zig build fmt

This commit is contained in:
Andrew Kelley 2025-02-22 17:03:24 -08:00
parent c0c911bfa7
commit eb3c7f5706
40 changed files with 1242 additions and 1246 deletions

View file

@ -614,7 +614,8 @@ pub fn hasRuntimeBitsInner(
strat,
zcu,
tid,
)) {
))
{
return true;
}
},

View file

@ -685,8 +685,7 @@ fn restoreState(func: *Func, state: State, deaths: []const Air.Inst.Index, compt
const ExpectedContents = [@typeInfo(RegisterManager.TrackedRegisters).array.len]RegisterLock;
var stack align(@max(@alignOf(ExpectedContents), @alignOf(std.heap.StackFallbackAllocator(0)))) =
if (opts.update_tracking)
{} else std.heap.stackFallback(@sizeOf(ExpectedContents), func.gpa);
if (opts.update_tracking) {} else std.heap.stackFallback(@sizeOf(ExpectedContents), func.gpa);
var reg_locks = if (opts.update_tracking) {} else try std.ArrayList(RegisterLock).initCapacity(
stack.get(),

View file

@ -82655,8 +82655,7 @@ fn restoreState(self: *CodeGen, state: State, deaths: []const Air.Inst.Index, co
const ExpectedContents = [@typeInfo(RegisterManager.TrackedRegisters).array.len]RegisterLock;
var stack align(@max(@alignOf(ExpectedContents), @alignOf(std.heap.StackFallbackAllocator(0)))) =
if (opts.update_tracking)
{} else std.heap.stackFallback(@sizeOf(ExpectedContents), self.gpa);
if (opts.update_tracking) {} else std.heap.stackFallback(@sizeOf(ExpectedContents), self.gpa);
var reg_locks = if (opts.update_tracking) {} else try std.ArrayList(RegisterLock).initCapacity(
stack.get(),

View file

@ -913,8 +913,7 @@ pub const Info = union(enum) {
.function => |lhs_function_info| lhs_function_info.param_ctypes.len ==
rhs_info.function.param_ctypes.len and
pool_adapter.eql(lhs_function_info.return_ctype, rhs_info.function.return_ctype) and
for (0..lhs_function_info.param_ctypes.len) |param_index|
{
for (0..lhs_function_info.param_ctypes.len) |param_index| {
if (!pool_adapter.eql(
lhs_function_info.param_ctypes.at(param_index, lhs_pool),
rhs_info.function.param_ctypes.at(param_index, rhs_pool),

View file

@ -859,8 +859,7 @@ pub const Object = struct {
builder.data_layout = try builder.fmt("{}", .{DataLayoutBuilder{ .target = target }});
const debug_compile_unit, const debug_enums_fwd_ref, const debug_globals_fwd_ref =
if (!builder.strip)
debug_info: {
if (!builder.strip) debug_info: {
// We fully resolve all paths at this point to avoid lack of
// source line info in stack traces or lack of debugging
// information which, if relative paths were used, would be

View file

@ -5080,8 +5080,7 @@ fn finishTransFnProto(
const is_noalias = param_qt.isRestrictQualified();
const param_name: ?[]const u8 =
if (fn_decl) |decl|
blk: {
if (fn_decl) |decl| blk: {
const param = decl.getParamDecl(@as(c_uint, @intCast(i)));
const param_name: []const u8 = try c.str(@as(*const clang.NamedDecl, @ptrCast(param)).getName_bytes_begin());
if (param_name.len < 1)