Skip to content

Commit 2493328

Browse files
authored
Rollup merge of #155690 - fneddy:fix_classify_union, r=jieyouxu
Fix classify_union to return Union for regular unions Commit 623c7d7 accidentally changed the return value from REGULAR_UNION to RegularEnum when converting string literals to enum values. Commit b17670d then renamed RegularUnion to Union, but the buggy return statement remained unchanged. This caused unions to be misclassified as enums, preventing LLDB from displaying union field contents.
2 parents b7f0235 + 2f99ab1 commit 2493328

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/etc/rust_types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,4 +130,4 @@ def classify_union(fields: List) -> RustType:
130130
assert len(fields) == 1
131131
return RustType.CompressedEnum
132132
else:
133-
return RustType.RegularEnum
133+
return RustType.Union

0 commit comments

Comments
 (0)