diff options
author | Arne Döring <arne.doering@gmx.net> | 2019-08-27 23:18:46 +0200 |
---|---|---|
committer | Andreas Rumpf <rumpf_a@web.de> | 2019-08-27 23:18:46 +0200 |
commit | d564130a3b2596161847d695329ad009e693358a (patch) | |
tree | 14ced0de16093871d709b6170a2018bbee897d19 /compiler/semfold.nim | |
parent | eff0837ff40e4a5f5659ff02a56d9936bcbd7bcd (diff) | |
download | Nim-d564130a3b2596161847d695329ad009e693358a.tar.gz |
Fix to int to biggest int (#12066)
* fix to(Biggest)Int * kill toFloat magics as well
Diffstat (limited to 'compiler/semfold.nim')
-rw-r--r-- | compiler/semfold.nim | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/compiler/semfold.nim b/compiler/semfold.nim index 564d7f067..bfb5077d6 100644 --- a/compiler/semfold.nim +++ b/compiler/semfold.nim @@ -196,10 +196,7 @@ proc evalOp(m: TMagic, n, a, b, c: PNode; g: ModuleGraph): PNode = else: result = newIntNodeT(toInt128(sonsLen(a)), n, g) of mUnaryPlusI, mUnaryPlusF64: result = a # throw `+` away - of mToFloat, mToBiggestFloat: - result = newFloatNodeT(toFloat64(getInt(a)), n, g) # XXX: Hides overflow/underflow - of mToInt, mToBiggestInt: result = newIntNodeT(system.toInt(getFloat(a)), n, g) of mAbsF64: result = newFloatNodeT(abs(getFloat(a)), n, g) of mAbsI: result = foldAbs(getInt(a), n, g) of mUnaryLt: result = foldSub(getOrdValue(a), One, n, g) |