Skip to content

Allow phantom-wrapped self-references in format definitions#317

Open
archaephyrryx wants to merge 2 commits into
archaephyrryx/opentype-colr-cpalfrom
archaephyrryx/phantom-recursion
Open

Allow phantom-wrapped self-references in format definitions#317
archaephyrryx wants to merge 2 commits into
archaephyrryx/opentype-colr-cpalfrom
archaephyrryx/phantom-recursion

Conversation

@archaephyrryx

Copy link
Copy Markdown
Contributor

Adds new format-definition methods FormatModule::define_format_phantom_rec{,_args, _views, _args_views} that allow for the description of formats that are indirectly self-referential within Phantom-wrapped contexts.

Applies several patches to typechecker and codegen to avoid infinite recursion when attempting to explore formats containing this indirect self-recursive embedding.

@archaephyrryx archaephyrryx requested a review from mikeday June 25, 2026 04:30
@archaephyrryx archaephyrryx changed the title Archaephyrryx/phantom recursion Allow phantom-wrapped self-references in format definitions Jun 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant