C99 scoping rules by default

This commit is contained in:
Leonardo Alt
2018-06-20 12:53:38 +02:00
parent ba7fbf11e7
commit 8862b3092b
35 changed files with 85 additions and 219 deletions
@@ -1,9 +1,7 @@
contract test {
function fun(uint256 a) {
while (true) { uint256 x = 1; break; continue; } x = 9;
function fun() public pure {
uint256 x;
while (true) { x = 1; break; continue; } x = 9;
}
}
// ----
// Warning: (20-115): No visibility specified. Defaulting to "public".
// Warning: (33-42): Unused function parameter. Remove or comment out the variable name to silence this warning.
// Warning: (20-115): Function state mutability can be restricted to pure