aboutsummaryrefslogtreecommitdiff
path: root/src/stage1/codegen.cpp
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2022-05-10 21:46:24 -0700
committerAndrew Kelley <andrew@ziglang.org>2022-05-10 21:50:55 -0700
commitb33c8b0b06dd6a24d89efb278eeb833db93b2f9b (patch)
tree6b5c91beeae7563c581279f8d08d553e08c40d3f /src/stage1/codegen.cpp
parentf5edf78eea403c14635a05e1729672cfb50aca89 (diff)
downloadzig-b33c8b0b06dd6a24d89efb278eeb833db93b2f9b.tar.gz
zig-b33c8b0b06dd6a24d89efb278eeb833db93b2f9b.zip
Sema: comptime float negation supports negative zero
When handling the `negate` ZIR instruction, Zig now checks for a comptime operand and handles it as a special case rather than lowering it as `0 - x` so that the expression `-x` where `x` is a floating point value known at compile-time, will get the negative zero bitwise representation.
Diffstat (limited to 'src/stage1/codegen.cpp')
0 files changed, 0 insertions, 0 deletions