| author | |
| committer | |
| log | 88acdb9aa6cdb8ea20e02c4d0f85be81f696897c |
| tree | cecbbdac819892394ae318bce3ed87583c618802 |
| parent | 212aa717d73866863c593033a1c8bd3c853150ed |
2 files changed, 11 insertions(+), 3 deletions(-)
lib/std/zig/render.zig+6-1| ... | ... | @@ -2043,7 +2043,12 @@ fn finishRenderBlock( |
| 2043 | 2043 | .simple_var_decl, |
| 2044 | 2044 | .aligned_var_decl, |
| 2045 | 2045 | => try renderVarDecl(r, tree.fullVarDecl(stmt).?, false, .semicolon), |
| 2046 | else => try renderExpression(r, stmt, .semicolon), | |
| 2046 | ||
| 2047 | else => { | |
| 2048 | if (!r.fixups.omit_nodes.contains(stmt)) { | |
| 2049 | try renderExpression(r, stmt, .semicolon); | |
| 2050 | } | |
| 2051 | }, | |
| 2047 | 2052 | } |
| 2048 | 2053 | } |
| 2049 | 2054 | ais.popIndent(); |
src/reduce/Walk.zig+5-2| ... | ... | @@ -134,8 +134,8 @@ fn walkMember(w: *Walk, decl: Ast.Node.Index) Error!void { |
| 134 | 134 | const body_node = datas[decl].rhs; |
| 135 | 135 | if (!isFnBodyGutted(ast, body_node)) { |
| 136 | 136 | try w.transformations.append(.{ .gut_function = decl }); |
| 137 | try walkExpression(w, body_node); | |
| 137 | 138 | } |
| 138 | try walkExpression(w, body_node); | |
| 139 | 139 | }, |
| 140 | 140 | .fn_proto_simple, |
| 141 | 141 | .fn_proto_multi, |
| ... | ... | @@ -648,7 +648,10 @@ fn walkBlock( |
| 648 | 648 | .aligned_var_decl, |
| 649 | 649 | => try walkLocalVarDecl(w, ast.fullVarDecl(stmt).?), |
| 650 | 650 | |
| 651 | else => try walkExpression(w, stmt), | |
| 651 | else => { | |
| 652 | try w.transformations.append(.{ .delete_node = stmt }); | |
| 653 | try walkExpression(w, stmt); | |
| 654 | }, | |
| 652 | 655 | } |
| 653 | 656 | } |
| 654 | 657 | } |