Skip to content

Change Union types sort order #22664

@quinnj

Description

@quinnj

The order of types in a Union should be mostly irrelevant, but with WIP work on inline, isbits Union types, the "default initialization" for Arrays requires the underlying Union selector byte to be zeroed out (otherwise an array element could be tagged as an "out of bounds" type for the Union). There are a few conveniences if the Union types sort order followed a pattern like:

  1. Singleton types
  2. Sizeof isbits types
  3. All reference types....alphabetically?

Metadata

Metadata

Assignees

No one assigned

    Labels

    types and dispatchTypes, subtyping and method dispatch

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions