diff options
| author | Ryan Liptak <squeek502@hotmail.com> | 2023-11-22 16:05:23 -0800 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2023-11-23 03:45:17 -0500 |
| commit | fcc071c9bd6b0c8e010957156505878ea6c0c55d (patch) | |
| tree | 8b2455bb168f2f08ee863161eb6682d864908afb /lib | |
| parent | f4e426a06c59922de80a572f8346f2797726b392 (diff) | |
| download | zig-fcc071c9bd6b0c8e010957156505878ea6c0c55d.tar.gz zig-fcc071c9bd6b0c8e010957156505878ea6c0c55d.zip | |
Remove unnecessary branch on absolute path
Also remove the TODO--it was added in fd067fbe8b14c445ed764da15fff5163156126df, but the current code no longer used that workaround, so this TODO didn't seem relevant anymore.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/std/debug.zig | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/std/debug.zig b/lib/std/debug.zig index 8c0992faee..129d933eb2 100644 --- a/lib/std/debug.zig +++ b/lib/std/debug.zig @@ -1078,13 +1078,8 @@ pub fn readElfDebugInfo( parent_mapped_mem: ?[]align(mem.page_size) const u8, ) !ModuleDebugInfo { nosuspend { - - // TODO https://github.com/ziglang/zig/issues/5525 const elf_file = (if (elf_filename) |filename| blk: { - break :blk if (fs.path.isAbsolute(filename)) - fs.openFileAbsolute(filename, .{ .intended_io_mode = .blocking }) - else - fs.cwd().openFile(filename, .{ .intended_io_mode = .blocking }); + break :blk fs.cwd().openFile(filename, .{ .intended_io_mode = .blocking }); } else fs.openSelfExe(.{ .intended_io_mode = .blocking })) catch |err| switch (err) { error.FileNotFound => return error.MissingDebugInfo, else => return err, |
