mirror of
https://github.com/ziglang/zig.git
synced 2024-11-27 07:32:44 +00:00
macho: remove unnecessary checks
This commit is contained in:
parent
9549b4acf6
commit
7d8b423477
@ -2171,7 +2171,7 @@ pub fn unwindFrame(context: *dwarf.UnwindContext, unwind_info: []const u8, modul
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Last index is a sentinel containing the highest address as its functionOffset
|
// Last index is a sentinel containing the highest address as its functionOffset
|
||||||
if (len == 0 or indices[left].secondLevelPagesSectionOffset == 0) return error.MissingUnwindInfo;
|
if (indices[left].secondLevelPagesSectionOffset == 0) return error.MissingUnwindInfo;
|
||||||
break :blk &indices[left];
|
break :blk &indices[left];
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -2216,7 +2216,6 @@ pub fn unwindFrame(context: *dwarf.UnwindContext, unwind_info: []const u8, modul
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (len == 0) return error.InvalidUnwindInfo;
|
|
||||||
break :blk .{
|
break :blk .{
|
||||||
.function_offset = entries[left].functionOffset,
|
.function_offset = entries[left].functionOffset,
|
||||||
.raw_encoding = entries[left].encoding,
|
.raw_encoding = entries[left].encoding,
|
||||||
@ -2248,7 +2247,6 @@ pub fn unwindFrame(context: *dwarf.UnwindContext, unwind_info: []const u8, modul
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (len == 0) return error.InvalidUnwindInfo;
|
|
||||||
const entry = entries[left];
|
const entry = entries[left];
|
||||||
const function_offset = second_level_index.functionOffset + entry.funcOffset;
|
const function_offset = second_level_index.functionOffset + entry.funcOffset;
|
||||||
if (entry.encodingIndex < header.commonEncodingsArrayCount) {
|
if (entry.encodingIndex < header.commonEncodingsArrayCount) {
|
||||||
|
Loading…
Reference in New Issue
Block a user