v2-periphery
v2-periphery copied to clipboard
Why overflows are desired in the `UniswapV2OracleLibrary` contract?
I've noticed there are comments for the following code saying addition overflow is desired
& subtraction overflow is desired
, what's the purpose behind? Can anyone enlighten me this? Thanks a lot!
https://github.com/Uniswap/v2-periphery/blob/master/contracts/libraries/UniswapV2OracleLibrary.sol#L28
This answer from stackoverflow gives a good explanation. I guess overflow do not change the final result, but I have't play this math game.