Revert "dwarf: fix LineNumberProgram check"

- needed/needs to go through review process

This reverts commit 746f65f8b3ce11d67d8fd392aea8bc05a24adae6.
This commit is contained in:
Michael Dusan 2021-04-12 06:55:12 -04:00
parent 746f65f8b3
commit 0fa1a2cb73
No known key found for this signature in database
GPG Key ID: ED4C5BA849FA1B74
2 changed files with 16 additions and 1 deletions

View File

@ -208,7 +208,7 @@ const LineNumberProgram = struct {
}
pub fn checkLineMatch(self: *LineNumberProgram) !?debug.LineInfo {
if (self.prev_address > 0 and self.target_address >= self.prev_address and self.target_address < self.address) {
if (self.target_address >= self.prev_address and self.target_address < self.address) {
const file_entry = if (self.prev_file == 0) {
return error.MissingDebugInfo;
} else if (self.prev_file - 1 >= self.file_entries.items.len) {

View File

@ -20,6 +20,11 @@ pub fn addCases(cases: *tests.StackTracesContext) void {
,
},
.ReleaseSafe = .{
.exclude = struct {
pub fn exclude() bool {
return if (std.builtin.object_format == .elf) true else false;
}
},
.exclude_os = .{
.windows, // segfault
},
@ -69,6 +74,11 @@ pub fn addCases(cases: *tests.StackTracesContext) void {
,
},
.ReleaseSafe = .{
.exclude = struct {
pub fn exclude() bool {
return if (std.builtin.object_format == .elf) true else false;
}
},
.exclude_os = .{
.windows, // segfault
},
@ -135,6 +145,11 @@ pub fn addCases(cases: *tests.StackTracesContext) void {
,
},
.ReleaseSafe = .{
.exclude = struct {
pub fn exclude() bool {
return if (std.builtin.object_format == .elf) true else false;
}
},
.exclude_os = .{
.windows, // segfault
},