Open fulldecent opened 4 years ago
Requesting assistance @jeff-aion
Experiments done here https://github.com/fulldecent/aion-aip040/commit/53b77b9f37fd18046db83cf6efa95c101c93e771
Found that BigInteger can exceed 2^255 but not when encoding to ABI.
BigIntegers are limited in the AVM ABI at:
https://github.com/aionnetwork/AVM/blob/master/org.aion.avm.userlib/src/org/aion/avm/userlib/abi/ABIStreamingEncoder.java#L480
a) This limitation is not specified in documentation. https://github.com/aionnetwork/docs/issues/64 b) The actual limits of the BigIntegers should be mentioned in code for clarity. I think it will be [-2^255, 2^255 - 1]. But the exact number is useful to document.