This commit is contained in:
Araq 2015-07-01 03:23:23 +02:00
commit 039da42401

View file

@ -543,7 +543,7 @@ proc foldConv*(n, a: PNode; check = false): PNode =
of tyFloat..tyFloat64:
case skipTypes(a.typ, abstractRange).kind
of tyInt..tyInt64, tyEnum, tyBool, tyChar:
result = newFloatNodeT(toFloat(int(getOrdValue(a))), n)
result = newFloatNodeT(toBiggestFloat(getOrdValue(a)), n)
else:
result = a
result.typ = n.typ