Expand description
Schema version for the LayoutTreeIR.
§Compatibility policy
- Field additions to existing structs in
crate::irbumpSCHEMA_VERSIONby one and append a migration line below. - Field removals or semantic-changing renames are breaking and require either a new major (e.g. v2) on top of v1 with a translation shim, or coordinated update of every consumer in the same PR. M1 ships v1; anything past v1 must justify the bump in this file’s migration log.
- Snapshots committed under tests/ir_snapshots/ carry the version
they were captured under via the
schema_versionfield at the root of the JSON. Tests that load older snapshots must reject mismatched versions explicitly rather than silently re-interpret.
§Migration log
- v1 (M1) — initial schema. Fields:
schema_version,rootwithchildren,field_kind,form_node_id,id,kind,overflow,page_index,presence,rect,som,value_hash.
Constants§
- SCHEMA_
VERSION - Current LayoutTreeIR schema version.