2019-06-30から1日間の記事一覧
今回の目標 今回は単項マイナス演算子だよ。 // double型 int main() { double x = 4.5, y = -x; printf("x = %f\ny = %f\n", x, y); } コード生成部 codegen_unaryopの該当部分を修正。 # 単行演算子のコード生成 def codegen_unaryop(op, operand) type = …
今回の目標 今回は単項マイナス演算子だよ。 // double型 int main() { double x = 4.5, y = -x; printf("x = %f\ny = %f\n", x, y); } コード生成部 codegen_unaryopの該当部分を修正。 # 単行演算子のコード生成 def codegen_unaryop(op, operand) type = …