diff options
author | Araq <rumpf_a@web.de> | 2014-03-27 19:20:59 +0100 |
---|---|---|
committer | Araq <rumpf_a@web.de> | 2014-03-27 19:20:59 +0100 |
commit | 3365b42bbe5e09f8e8a739597ae5e49e2ff2c259 (patch) | |
tree | 4d8ded5ab336ab4a3e07679dbc1ddd1d1cf5fbd0 /compiler/vm.nim | |
parent | dc956c485aa9d8becd3d9eb3c2086ebac3b6eeed (diff) | |
download | Nim-3365b42bbe5e09f8e8a739597ae5e49e2ff2c259.tar.gz |
fixes #1009
Diffstat (limited to 'compiler/vm.nim')
-rw-r--r-- | compiler/vm.nim | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/vm.nim b/compiler/vm.nim index 268289aca..0d5386502 100644 --- a/compiler/vm.nim +++ b/compiler/vm.nim @@ -318,7 +318,7 @@ proc opConv*(dest: var TFullReg, src: TFullReg, desttyp, srctyp: PType): bool = of tyFloat..tyFloat64: dest.intVal = system.toInt(src.floatVal) else: - dest.intVal = src.intVal and ((1 shl desttyp.size)-1) + dest.intVal = src.intVal and ((1 shl (desttyp.size*8))-1) of tyFloat..tyFloat64: if dest.kind != rkFloat: myreset(dest); dest.kind = rkFloat |