mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
Fix #complete switch on pointers to unions #286
This commit is contained in:
+1
-1
@@ -1008,7 +1008,7 @@ void check_type_switch_stmt(CheckerContext *ctx, Ast *node, u32 mod_flags) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (complete) {
|
if (complete) {
|
||||||
Type *ut = base_type(x.type);
|
Type *ut = base_type(type_deref(x.type));
|
||||||
GB_ASSERT(is_type_union(ut));
|
GB_ASSERT(is_type_union(ut));
|
||||||
auto variants = ut->Union.variants;
|
auto variants = ut->Union.variants;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user