Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Storage corruption when addition on storage element overflows #1306
The following code returns 1 instead of 0 because the addition overflows. The assembly code shows that the AND mask is applied before the addition and not after, resulting in the corruption of b.
I suppose that writing in a should not corrupt b in any case.
Solidity version: 0.4.3+commit.2353da71.Emscripten.clang