solidity/test/libsolidity/syntaxTests/controlFlow/unreachableCode/if_both_return.sol

13 lines
227 B
Solidity
Raw Normal View History

2019-01-08 18:33:46 +00:00
contract C {
function f(bool c) public pure {
if (c) {
return;
} else {
return;
}
return; // unreachable
}
}
// ----
// Warning 5740: (142-149): Unreachable code.