| ... | @@ -11119,10 +11119,9 @@ static TypeTableEntry *ir_analyze_instruction_unwrap_maybe(IrAnalyze *ira, | ... | @@ -11119,10 +11119,9 @@ static TypeTableEntry *ir_analyze_instruction_unwrap_maybe(IrAnalyze *ira, |
| 11119 | ConstExprValue *val = ir_resolve_const(ira, value, UndefBad); | 11119 | ConstExprValue *val = ir_resolve_const(ira, value, UndefBad); |
| 11120 | if (!val) | 11120 | if (!val) |
| 11121 | return ira->codegen->builtin_types.entry_invalid; | 11121 | return ira->codegen->builtin_types.entry_invalid; |
| 11122 | assert(val->data.x_ptr.special == ConstPtrSpecialRef); | 11122 | ConstExprValue *maybe_val = const_ptr_pointee(ira->codegen, val); |
| 11123 | ConstExprValue *maybe_val = val->data.x_ptr.data.ref.pointee; | | |
| 11124 | | 11123 | |
| 11125 | if (maybe_val->special != ConstValSpecialRuntime) { | 11124 | if (val->data.x_ptr.mut != ConstPtrMutRuntimeVar) { |
| 11126 | if (!maybe_val->data.x_maybe) { | 11125 | if (!maybe_val->data.x_maybe) { |
| 11127 | ir_add_error(ira, &unwrap_maybe_instruction->base, buf_sprintf("unable to unwrap null")); | 11126 | ir_add_error(ira, &unwrap_maybe_instruction->base, buf_sprintf("unable to unwrap null")); |
| 11128 | return ira->codegen->builtin_types.entry_invalid; | 11127 | return ira->codegen->builtin_types.entry_invalid; |