Implement Control Flow Statements in Kym #37
|
@ -42,10 +42,13 @@ pub const BinaryOperator = enum {
|
|||
"`");
|
||||
}
|
||||
|
||||
// TODO: Remove once Zig has fixed struct self-reassignment.
|
||||
const unnecessary_temp = try coral.io.allocate_one(allocator, expression);
|
||||
|
||||
expression = .{
|
||||
.binary_operation = .{
|
||||
.operator = operator,
|
||||
.lhs_expression = try coral.io.allocate_one(allocator, expression),
|
||||
.lhs_expression = unnecessary_temp,
|
||||
.rhs_expression = try coral.io.allocate_one(allocator, try build_next(self)),
|
||||
},
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue