Skip to content

Merge Type and Term in hugr-core. #2341

@zrho

Description

@zrho

#2309 merges TypeArg and TypeParam into one data structure in hugr-core. We should further merge Type into Term.

Related Issues

  • The code currently special cases lists of Types to deal with "row variables". To enable a clean merger, we'd need to get rid of row variables first (see No more row variables #2310).
  • The capability to define custom Types would be extended to custom Terms that aren't runtime types (which would solve Allow custom TypeArgs and TypeParams. #2296).
  • Merging Types and Terms would allow runtime types to profit from the sharing enabled by reference counted terms (see feat!: Reference counted terms #2338). Runtime types are the primary source of heavily duplicated terms, so this could have a large performance benefit (especially on model deserialisation).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions