[mypyc] Fixes to float to int conversion (#14936)
Fix undefined behavior due to converting a negative float to an unsigned
integer type. Fix edge cases on 32-bit platforms.
The first issue was caught by the testI32BasicOps test case, but only in
some configurations, it looks like.