| ... | ... | @@ -928,13 +928,7 @@ pub fn suspendExpr( |
| 928 | 928 | try astgen.errNoteNode(gz.suspend_node, "other suspend block here", .{}), |
| 929 | 929 | }); |
| 930 | 930 | } |
| 931 | | if (body_node == 0) { |
| 932 | | // Accepted proposal to remove block-less suspend from the language: |
| 933 | | // https://github.com/ziglang/zig/issues/8603 |
| 934 | | // TODO: simplify the parser and make this an assert instead of |
| 935 | | // a compile error. |
| 936 | | return astgen.failNode(node, "suspend without a block", .{}); |
| 937 | | } |
| 931 | assert(body_node != 0); |
| 938 | 932 | |
| 939 | 933 | const suspend_inst = try gz.addBlock(.suspend_block, node); |
| 940 | 934 | try gz.instructions.append(gpa, suspend_inst); |