mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
27 lines
394 B
Plaintext
27 lines
394 B
Plaintext
{
|
|
for {
|
|
let a := 2
|
|
// Should not be removed, even though you might think
|
|
// it goes out of scope
|
|
a := 3
|
|
} a { a := add(a, 1) }
|
|
{
|
|
a := 7
|
|
}
|
|
}
|
|
// ----
|
|
// redundantAssignEliminator
|
|
// {
|
|
// for {
|
|
// let a := 2
|
|
// a := 3
|
|
// }
|
|
// a
|
|
// {
|
|
// a := add(a, 1)
|
|
// }
|
|
// {
|
|
// a := 7
|
|
// }
|
|
// }
|