diff options
Diffstat (limited to 'src/InternPool.zig')
| -rw-r--r-- | src/InternPool.zig | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/src/InternPool.zig b/src/InternPool.zig index fdeddcfa2f..c0b4d2f446 100644 --- a/src/InternPool.zig +++ b/src/InternPool.zig @@ -2029,15 +2029,7 @@ pub const Key = union(enum) { pub const NamespaceType = union(enum) { /// This type corresponds to an actual source declaration, e.g. `struct { ... }`. /// It is hashed based on its ZIR instruction index and set of captures. - declared: struct { - /// A `struct_decl`, `union_decl`, `enum_decl`, or `opaque_decl` instruction. - zir_index: TrackedInst.Index, - /// The captured values of this type. These values must be fully resolved per the language spec. - captures: union(enum) { - owned: CaptureValue.Slice, - external: []const CaptureValue, - }, - }, + declared: Declared, /// This type is an automatically-generated enum tag type for a union. /// It is hashed based on the index of the union type it corresponds to. generated_tag: struct { @@ -2053,6 +2045,16 @@ pub const Key = union(enum) { /// A hash of this type's attributes, fields, etc, generated by Sema. type_hash: u64, }, + + pub const Declared = struct { + /// A `struct_decl`, `union_decl`, `enum_decl`, or `opaque_decl` instruction. + zir_index: TrackedInst.Index, + /// The captured values of this type. These values must be fully resolved per the language spec. + captures: union(enum) { + owned: CaptureValue.Slice, + external: []const CaptureValue, + }, + }; }; pub const FuncType = struct { |
