Skip to content

Commit

Permalink
fix: pair type checking in safe mode
Browse files Browse the repository at this point in the history
  • Loading branch information
sno2 committed Nov 5, 2024
1 parent 80cc77c commit d77da5b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/CodeGen.zig
Original file line number Diff line number Diff line change
Expand Up @@ -485,8 +485,8 @@ fn equal(cg: *CodeGen, a: Type, b: Type) bool {
return cg.equal(x, y);
},
.pair => {
const x = cg.type_extras.items[a.ref..][0..2];
const y = cg.type_extras.items[b.ref..][0..2];
const x = cg.type_extras.items[a.pair..][0..2];
const y = cg.type_extras.items[b.pair..][0..2];
return cg.equal(x[0], y[0]) and cg.equal(x[1], y[1]);
},
.list => {
Expand Down

0 comments on commit d77da5b

Please sign in to comment.