web3 / web3.js

Collection of comprehensive TypeScript libraries for Interaction with the Ethereum JSON RPC API and utility functions.
https://web3js.org/
Other
19.38k stars 4.97k forks source link

web3.js maps solidity uint256 to negative bignumbers #294

Closed ralph-pichler closed 9 years ago

ralph-pichler commented 9 years ago

Example: contract x { function getUnsignedValue() constant returns (uint256 rval) { return uint256(sha3(0)); } }

calling getUnsignedValue() with web3.js returns a negative bigNumber

debris commented 9 years ago

fixed in bbe031a35f07d24c715baf3a5e3b57b9538f9bdf . Thanks for report. It was new bug, introduced after latest improvements in solidity coder.