David Thrane Christiansen
d8cbf1cefc
doc: docstring review for monads and transformers ( #7548 )
...
This PR adds missing monad transformer docstrings and makes their style
consistent.
---------
Co-authored-by: Bhavik Mehta <bm489@cam.ac.uk>
2025-03-20 12:18:46 +00:00
Kyle Miller
28cf146d00
fix: make sure monad lift coercion elaborator has no side effects ( #6024 )
...
This PR fixes a bug where the monad lift coercion elaborator would
partially unify expressions even if they were not monads. This could be
taken advantage of to propagate information that could help elaboration
make progress, for example the first `change` worked because the monad
lift coercion elaborator was unifying `@Eq _ _` with `@Eq (Nat × Nat)
p`:
```lean
example (p : Nat × Nat) : p = p := by
change _ = ⟨_, _⟩ -- used to work (yielding `p = (p.fst, p.snd)`), now it doesn't
change ⟨_, _⟩ = _ -- never worked
```
As such, this is a breaking change; you may need to adjust expressions
to include additional implicit arguments.
2024-11-13 16:22:31 +00:00
Leonardo de Moura
794228a982
refactor: Offset.lean and related files ( #3614 )
...
Motivation: avoid the unfold and check idiom.
This commit also minimize dependencies at `Offset.lean`.
closes #2615
2024-03-05 19:40:15 -08:00
Henrik Böving
23e49eb519
perf: add prelude to all Lean modules
2024-02-18 14:55:17 -08:00
Gabriel Ebner
3ab859553e
fix: allow function coercion to assign universe mvars
2023-03-08 15:54:07 -08:00
Gabriel Ebner
6083b01c86
fix: remove maxCoeSize option
2022-12-22 02:02:55 +01:00
Gabriel Ebner
e59ddb0c16
refactor: replace hardcoded list of coercions by attribute
2022-12-21 04:24:39 +01:00
Gabriel Ebner
e386d5941e
refactor: replace ignoreLevelMVarDepth by levelAssignDepth
2022-12-19 20:14:17 +01:00
Gabriel Ebner
045a71ab33
hack: ignore maxCoeSize for monad coercions
2022-10-14 12:08:10 -07:00
Gabriel Ebner
1c561c39a8
feat: function coercions with unification
2022-10-14 12:08:10 -07:00
Sebastian Ullrich
e81ba951c6
fix: Core.transform API and uses
2022-08-25 19:07:42 -07:00
Leonardo de Moura
6f416147b4
chore: rename coeM and liftCoeM
2022-01-20 15:33:17 -08:00
Leonardo de Moura
2192e6148b
chore: remove coe, coeSort, and coeFun abbreviations
...
The notation `↑ e` is now expanded eagerly.
See #403
2022-01-20 15:19:06 -08:00
Leonardo de Moura
3c17755730
chore: prepare to remove coe definitions
...
The notation `↑ e` will eagerly expand the coersion.
See #403
2022-01-20 15:07:54 -08:00
Leonardo de Moura
f07b9926b1
feat: unfold coercions and coeFun, coeSort, coeM, liftCoeM
...
TODO: `coe`
2021-02-14 10:27:34 -08:00
Leonardo de Moura
7e3bc30674
feat: add expandCoe
2021-02-14 10:03:44 -08:00