summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y2
1 files changed, 1 insertions, 1 deletions
diff --git a/parse.y b/parse.y
index 5948f6e2f6..ec25402aec 100644
--- a/parse.y
+++ b/parse.y
@@ -11924,7 +11924,7 @@ negate_lit(struct parser_params *p, VALUE lit)
RCOMPLEX_SET_IMAG(lit, negate_lit(p, RCOMPLEX(lit)->imag));
break;
case T_FLOAT:
- RFLOAT(lit)->float_value = -RFLOAT_VALUE(lit);
+ lit = DBL2NUM(-RFLOAT_VALUE(lit));
break;
unknown:
default: