authorgravatar for luuk@degram.devLuuk de Gram <luuk@degram.dev> 2024-03-08 18:18:40+01:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2024-03-14 02:57:46-07:00
log0103c4bf78d26ba5954d3459b64d953b2698cdf6
tree5975df05f9ed4fc713e7ffcb4a07c5728f6ee14b
parent778ab767b1e367233a1a3284e2c24d2c27b44602

std: make std.dwarf.FixedBufferReader public

Also fixes a compile-error as the field `is_64` no longer exists.

1 files changed, 2 insertions(+), 2 deletions(-)

lib/std/dwarf.zig+2-2
...@@ -2437,7 +2437,7 @@ pub const EntryHeader = struct {...@@ -2437,7 +2437,7 @@ pub const EntryHeader = struct {
24372437
2438 /// The length of the entry including the ID field, but not the length field itself2438 /// The length of the entry including the ID field, but not the length field itself
2439 pub fn entryLength(self: EntryHeader) usize {2439 pub fn entryLength(self: EntryHeader) usize {
2440 return self.entry_bytes.len + @as(u8, if (self.is_64) 8 else 4);2440 return self.entry_bytes.len + @as(u8, if (self.format == .@"64") 8 else 4);
2441 }2441 }
24422442
2443 /// Reads a header for either an FDE or a CIE, then advances the fbr to the position after the trailing structure.2443 /// Reads a header for either an FDE or a CIE, then advances the fbr to the position after the trailing structure.
...@@ -2735,7 +2735,7 @@ fn pcRelBase(field_ptr: usize, pc_rel_offset: i64) !usize {...@@ -2735,7 +2735,7 @@ fn pcRelBase(field_ptr: usize, pc_rel_offset: i64) !usize {
27352735
2736// Reading debug info needs to be fast, even when compiled in debug mode,2736// Reading debug info needs to be fast, even when compiled in debug mode,
2737// so avoid using a `std.io.FixedBufferStream` which is too slow.2737// so avoid using a `std.io.FixedBufferStream` which is too slow.
2738const FixedBufferReader = struct {2738pub const FixedBufferReader = struct {
2739 buf: []const u8,2739 buf: []const u8,
2740 pos: usize = 0,2740 pos: usize = 0,
2741 endian: std.builtin.Endian,2741 endian: std.builtin.Endian,