| ... | ... | @@ -126,8 +126,7 @@ pub fn generate(file: *C, decl: *Decl) !void { |
| 126 | 126 | const target = func_val.func.owner_decl; |
| 127 | 127 | const target_ty = target.typed_value.most_recent.typed_value.ty; |
| 128 | 128 | const ret_ty = target_ty.fnReturnType().tag(); |
| 129 | | if (ret_ty != .void and ret_ty != .noreturn) { |
| 130 | | // TODO: don't do this if we're actually using the value |
| 129 | if (target_ty.fnReturnType().hasCodeGenBits()) { |
| 131 | 130 | try writer.print("(void)", .{}); |
| 132 | 131 | } |
| 133 | 132 | const tname = mem.spanZ(target.name); |