| ... | @@ -26641,13 +26641,12 @@ fn zirFuncFancy(sema: *Sema, block: *Block, inst: Zir.Inst.Index) CompileError!A | ... | @@ -26641,13 +26641,12 @@ fn zirFuncFancy(sema: *Sema, block: *Block, inst: Zir.Inst.Index) CompileError!A |
| 26641 | break :cc .auto; | 26641 | break :cc .auto; |
| 26642 | }; | 26642 | }; |
| 26643 | | 26643 | |
| 26644 | const ret_ty: Type = if (extra.data.bits.ret_ty_is_generic) | 26644 | const ret_ty: Type = if (extra.data.bits.has_ret_ty_body) blk: { |
| 26645 | .generic_poison | | |
| 26646 | else if (extra.data.bits.has_ret_ty_body) blk: { | | |
| 26647 | const body_len = sema.code.extra[extra_index]; | 26645 | const body_len = sema.code.extra[extra_index]; |
| 26648 | extra_index += 1; | 26646 | extra_index += 1; |
| 26649 | const body = sema.code.bodySlice(extra_index, body_len); | 26647 | const body = sema.code.bodySlice(extra_index, body_len); |
| 26650 | extra_index += body.len; | 26648 | extra_index += body.len; |
| | 26649 | if (extra.data.bits.ret_ty_is_generic) break :blk .generic_poison; |
| 26651 | | 26650 | |
| 26652 | const val = try sema.resolveGenericBody(block, ret_src, body, inst, Type.type, .{ .simple = .function_ret_ty }); | 26651 | const val = try sema.resolveGenericBody(block, ret_src, body, inst, Type.type, .{ .simple = .function_ret_ty }); |
| 26653 | const ty = val.toType(); | 26652 | const ty = val.toType(); |
| ... | @@ -26655,6 +26654,8 @@ fn zirFuncFancy(sema: *Sema, block: *Block, inst: Zir.Inst.Index) CompileError!A | ... | @@ -26655,6 +26654,8 @@ fn zirFuncFancy(sema: *Sema, block: *Block, inst: Zir.Inst.Index) CompileError!A |
| 26655 | } else if (extra.data.bits.has_ret_ty_ref) blk: { | 26654 | } else if (extra.data.bits.has_ret_ty_ref) blk: { |
| 26656 | const ret_ty_ref: Zir.Inst.Ref = @enumFromInt(sema.code.extra[extra_index]); | 26655 | const ret_ty_ref: Zir.Inst.Ref = @enumFromInt(sema.code.extra[extra_index]); |
| 26657 | extra_index += 1; | 26656 | extra_index += 1; |
| | 26657 | if (extra.data.bits.ret_ty_is_generic) break :blk .generic_poison; |
| | 26658 | |
| 26658 | const ret_ty_air_ref = try sema.resolveInst(ret_ty_ref); | 26659 | const ret_ty_air_ref = try sema.resolveInst(ret_ty_ref); |
| 26659 | const ret_ty_val = try sema.resolveConstDefinedValue(block, ret_src, ret_ty_air_ref, .{ .simple = .function_ret_ty }); | 26660 | const ret_ty_val = try sema.resolveConstDefinedValue(block, ret_src, ret_ty_air_ref, .{ .simple = .function_ret_ty }); |
| 26660 | break :blk ret_ty_val.toType(); | 26661 | break :blk ret_ty_val.toType(); |