From 3436ee9deddf21594a0b4fb3640a7596ea078093 Mon Sep 17 00:00:00 2001 From: Jarred Sumner Date: Sat, 29 May 2021 13:33:48 -0700 Subject: microp Former-commit-id: b876a8d4800779c6728a61ec51cd168d7307bc9d --- src/ast/base.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/ast') diff --git a/src/ast/base.zig b/src/ast/base.zig index 3f10beb37..361339f7f 100644 --- a/src/ast/base.zig +++ b/src/ast/base.zig @@ -57,7 +57,7 @@ pub const Ref = packed struct { } pub fn eql(ref: Ref, b: Ref) bool { - return ref.inner_index == b.inner_index and ref.source_index == b.source_index; + return std.mem.readIntNative(u64, std.mem.asBytes(&ref)) == std.mem.readIntNative(u64, std.mem.asBytes(&b)); } pub fn jsonStringify(self: *const Ref, options: anytype, writer: anytype) !void { -- cgit v1.2.3