def inl.seal

emerging-eztoml@0.9.0.0 · main.bend:2867

import emerging-eztoml@0.9.0.0/main.bend as EmergingEztoml
import Base

2867# an inline table is closed once written: the tables its dotted keys made,
2868# open while it was read, close with it
2869def inl.seal(rows: List<&2, Val>) -> List<&2, Val>:
2870  match rows:
2871    case []:
2872      []
2873    case VPair{name, VHead{_path, sub}} <> t:
2874      VPair{name, VInl{inl.seal(sub)}} <> inl.seal(t)
2875    case h <> t:
2876      h <> inl.seal(t)

Uses (2)

Used by (1)