leanprover / theorem_proving_in_lean4

Theorem Proving in Lean 4
https://leanprover.github.io/theorem_proving_in_lean4/
Apache License 2.0
164 stars 92 forks source link

Update type_classes.md #77

Open Erotemic opened 1 year ago

Erotemic commented 1 year ago

In https://lean-lang.org/theorem_proving_in_lean4/type_classes.html I noticed an error. In the 5th example part of it states:

#eval double (10 : Int)
-- 100

However, the actual evaluation returns 10 as-is. I'm not sure if this was meant to return 100 or 10 (the correct fix depends on the answer to that question), but assuming we really did want 100 there as a way to show how the resolution of Nat and Int are different, then this should be the correct patch.