bugfix: int32 for num >= -2^31 and num <= 2^31-1, and int64 for other