src/AstGen.zig | 21 +++++--- src/Module.zig | 31 +++++++++++- src/Sema.zig | 84 +++++++++++++++++++------------- test/cases/compile_errors/extern_union_given_enum_tag_type.zig | 20 ++++++++ test/cases/compile_errors/non-enum_tag_type_passed_to_union.zig | 13 +++++ test/cases/compile_errors/non-integer_tag_type_to_automatic_union_enum.zig | 13 +++++ test/cases/compile_errors/non-integer_tag_type_to_enum.zig | 13 +++++ test/cases/compile_errors/stage1/obj/extern_union_given_enum_tag_type.zig | 20 -------- test/cases/compile_errors/stage1/obj/non-enum_tag_type_passed_to_union.zig | 13 ----- test/cases/compile_errors/stage1/obj/non-integer_tag_type_to_automatic_union_enum.zig | 13 ----- test/cases/compile_errors/stage2/union_enum_field_missing.zig | 2 +- test/cases/compile_errors/stage2/union_extra_field.zig | 2 +- test/cases/compile_errors/switch_expression-missing_enumeration_prong.zig | 2 +- test/cases/compile_errors/switch_on_enum_with_1_field_with_no_prongs.zig | 2 +- test/cases/compile_errors/switching_with_non-exhaustive_enums.zig | 2 +- test/cases/compile_errors/union_with_specified_enum_omits_field.zig | 2 +- test/stage2/cbe.zig | 2 +- 17 files changed, 159 insertions(+), 96 deletions(-)