mirror of
https://github.com/status-im/web3.js.git
synced 2025-02-23 19:48:13 +00:00
There was an issue in combination of `solidity.formatters.formatInputInt` and `utils.toTwosComplement` where the value was rounded *after* performing the toTwosComplement. This caused negative floats to round _UP_ instead of rounding _DOWN_. I'm not sure if this is a bug or intentional, but from reading the code it appears to be intended to be rounded down. Added simple unit test to demonstrate the behavior