Skip to content

Commit

Permalink
fix: use Expr.equal instead of Expr.eqv
Browse files Browse the repository at this point in the history
`Expr.equal` takes binder names into account.
  • Loading branch information
leodemoura committed Nov 16, 2024
1 parent 1d3f02e commit 8be8441
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/Lean/Meta/Basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,12 @@ structure ExprConfigCacheKey where
private mk ::
expr : Expr
configKey : UInt64
deriving Inhabited, BEq
deriving Inhabited

instance : BEq ExprConfigCacheKey where
beq a b :=
Expr.equal a.expr b.expr &&
a.configKey == b.configKey

instance : Hashable ExprConfigCacheKey where
hash := fun { expr, configKey } => mixHash (hash expr) (hash configKey)
Expand Down

0 comments on commit 8be8441

Please sign in to comment.