News for hackers. Stuff that matters.
Re:Weird Expressions in Rust by nialv7 on Saturday June 28, 2025 @01:19AM (#44402452)
I recently realized (by playing with Lean) that coercing of "!" is because of the principle of explosion [1]. Basically propositions are types in Lean, and proofs are instances of those types. A proposition that is false doesn't have any instances, so they are like "!". Principle of explosion says ∀ P, False -> P, which is exactly the type signature for "!" coercing.

[1]: https://leanprover-community.github.io/mathlib4_docs/Init/Pr...

There are no comments on this comment yet.