| ... | @@ -13550,7 +13550,7 @@ fn countBodyLenAfterFixups(astgen: *AstGen, body: []const Zir.Inst.Index) u32 { | ... | @@ -13550,7 +13550,7 @@ fn countBodyLenAfterFixups(astgen: *AstGen, body: []const Zir.Inst.Index) u32 { |
| 13550 | | 13550 | |
| 13551 | fn emitDbgStmt(gz: *GenZir, lc: LineColumn) !void { | 13551 | fn emitDbgStmt(gz: *GenZir, lc: LineColumn) !void { |
| 13552 | if (gz.is_comptime) return; | 13552 | if (gz.is_comptime) return; |
| 13553 | if (gz.instructions.items.len > 0) { | 13553 | if (gz.instructions.items.len > gz.instructions_top) { |
| 13554 | const astgen = gz.astgen; | 13554 | const astgen = gz.astgen; |
| 13555 | const last = gz.instructions.items[gz.instructions.items.len - 1]; | 13555 | const last = gz.instructions.items[gz.instructions.items.len - 1]; |
| 13556 | if (astgen.instructions.items(.tag)[@intFromEnum(last)] == .dbg_stmt) { | 13556 | if (astgen.instructions.items(.tag)[@intFromEnum(last)] == .dbg_stmt) { |
| ... | @@ -13576,7 +13576,7 @@ fn emitDbgStmt(gz: *GenZir, lc: LineColumn) !void { | ... | @@ -13576,7 +13576,7 @@ fn emitDbgStmt(gz: *GenZir, lc: LineColumn) !void { |
| 13576 | /// instructions; fix up Sema so we don't need it! | 13576 | /// instructions; fix up Sema so we don't need it! |
| 13577 | fn emitDbgStmtForceCurrentIndex(gz: *GenZir, lc: LineColumn) !void { | 13577 | fn emitDbgStmtForceCurrentIndex(gz: *GenZir, lc: LineColumn) !void { |
| 13578 | const astgen = gz.astgen; | 13578 | const astgen = gz.astgen; |
| 13579 | if (gz.instructions.items.len > 0 and | 13579 | if (gz.instructions.items.len > gz.instructions_top and |
| 13580 | @intFromEnum(gz.instructions.items[gz.instructions.items.len - 1]) == astgen.instructions.len - 1) | 13580 | @intFromEnum(gz.instructions.items[gz.instructions.items.len - 1]) == astgen.instructions.len - 1) |
| 13581 | { | 13581 | { |
| 13582 | const last = astgen.instructions.len - 1; | 13582 | const last = astgen.instructions.len - 1; |