diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2022-08-24 15:57:44 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-08-24 15:57:44 -0400 |
| commit | 2a96209c4060bbf8a41fbe34e687a7a4741d2fe1 (patch) | |
| tree | 11594b42c723162c304f5cbce7259c856718458b /lib/std/elf.zig | |
| parent | 80b8294bccdbdf3bc0dd9248676e5c9718354125 (diff) | |
| parent | 7b14d614d91df7b9b5d802f34bf628293fc714f0 (diff) | |
| download | zig-2a96209c4060bbf8a41fbe34e687a7a4741d2fe1.tar.gz zig-2a96209c4060bbf8a41fbe34e687a7a4741d2fe1.zip | |
Merge pull request #12574 from Vexu/remove-bit-op-type-param
stage2+stage1: remove type parameter from bit builtins
Diffstat (limited to 'lib/std/elf.zig')
| -rw-r--r-- | lib/std/elf.zig | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/std/elf.zig b/lib/std/elf.zig index d80ae2f6a0..16581b7782 100644 --- a/lib/std/elf.zig +++ b/lib/std/elf.zig @@ -387,7 +387,7 @@ pub const Header = struct { const machine = if (need_bswap) blk: { const value = @enumToInt(hdr32.e_machine); - break :blk @intToEnum(EM, @byteSwap(@TypeOf(value), value)); + break :blk @intToEnum(EM, @byteSwap(value)); } else hdr32.e_machine; return @as(Header, .{ @@ -511,7 +511,7 @@ pub fn SectionHeaderIterator(ParseSource: anytype) type { pub fn int(is_64: bool, need_bswap: bool, int_32: anytype, int_64: anytype) @TypeOf(int_64) { if (is_64) { if (need_bswap) { - return @byteSwap(@TypeOf(int_64), int_64); + return @byteSwap(int_64); } else { return int_64; } @@ -522,7 +522,7 @@ pub fn int(is_64: bool, need_bswap: bool, int_32: anytype, int_64: anytype) @Typ pub fn int32(need_bswap: bool, int_32: anytype, comptime Int64: anytype) Int64 { if (need_bswap) { - return @byteSwap(@TypeOf(int_32), int_32); + return @byteSwap(int_32); } else { return int_32; } |
