hyperledger / solang

Solidity Compiler for Solana and Polkadot
https://solang.readthedocs.io/
Apache License 2.0
1.25k stars 210 forks source link

Produce error diagnostics if overflow occurs in constant folding #1488

Closed seanyoung closed 1 year ago

seanyoung commented 1 year ago

The negate operator does not check for overflow, add this too.

Fixes https://github.com/hyperledger/solang/issues/1484

LucasSte commented 1 year ago

Looks good. I just couldn't find the examples I pointed out.

Found them!