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

Use eval! to evaluate functions that use sorry. #133

Open lcrh opened 1 month ago

lcrh commented 1 month ago

Perhaps the behavior changed here from previous versions of lean, but running the code from the book locally in vscode, I got the following error:

cannot evaluate expression that depends on the `sorry` axiom.
Use `#eval!` to evaluate nevertheless (which may cause lean to crash).