* BUG: Fix String -> Long conversion.


git-svn-id: svn://localhost/gambas/trunk@4783 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
Emil Lenngren 2012-05-26 17:59:14 +00:00
parent 7fb2fefccd
commit 743bbc7a2a

View File

@ -438,7 +438,7 @@ __s2l:
create_throw(E_TYPE, JIF.F_TYPE_get_name(type), JIF.F_TYPE_get_name(value->type));
});
llvm::Value* intval = read_value(addr, T_INTEGER);
llvm::Value* intval = read_value(addr, type == T_LONG ? T_LONG : T_INTEGER);
if (type < T_INTEGER)
intval = builder->CreateTrunc(intval, TYPE_llvm(type));