Repository navigation
Commit eaa4d0a
committed
Read and write type nodes through the accessors in Ctype
Ctype, the core of unification, instantiation, generalization and the
occur checks, now reads type nodes only through `get_desc`, `get_level`
and `get_id`, and makes its unlogged writes (copy marks, level marks,
temporary links, writes after `log_type`) through `Transient_expr`. Its
local `get_level env p`, the binding level of a path, is renamed
`get_path_level` so that it does not shadow `Types.get_level`.
Review: Does the conversion change evaluation order, sharing or
allocation? No. Writes still evaluate the new descriptor before storing
it, `filter_visited` returns the same list cell, and the already-copied
variant case in `copy` matches with a guard instead of building an option.
Signed-off-by: Jono Prest <jjprest@gmail.com>1 parent e4f6ac2 commit eaa4d0a
2 files changed
Lines changed: 246 additions & 216 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
0 commit comments