Skip to content

Make segment and term bijective ish #2080

@disconcision

Description

@disconcision

It would be nice to be able to alternate doing text-like transformations using segment and AST-like transformations using term without having to worry about losing information when switching between these two representations. Establishing a true bijection is likely unrealistic due to the inherent permissivity of segment, but we might be able to achieve a weaker goal; something like bijectivity for all segments which are actually possibly to create via edit actions from the empty program. Full bijection isn't really a practical necessity, but given the complexity of the system it would be nice if we can get to a point close enough where a round-tripping property based test would have low enough false positives to be useful.

There are at least four main things we need to get here:

  1. Preserve secondary in terms via annotations: Secondary in terms #2077 (complete)
  2. Preserve projectors in terms via a wrapping form: Projector in terms #2078 (complete)
  3. Perserve tile incompleteness via annotations: Canonical completion #2079 (draft)
  4. Reduce segment surface area by replacing molds/labels in tiles with an enum (TODO)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions