3 ms·
Because I have seen more than once devs forgetting to add a 'break;', resulting in more or less subtle bugs. The kotlin/swift way of declaring this flow does n
by on_and_off 9y ago
Because I have seen more than once devs forgetting to add a 'break;', resulting in more or less subtle bugs.
The kotlin/swift way of declaring this flow does not let you do this mistake.
- m2ger 9y agoI recommend using ErrorProne in Your projects. There are several problems its compiler will catch and fall through begin one of them: http://errorprone.info/bugpattern/FallThrough http://errorprone.info/bugpattern/FallThrough It might take quite a lot of work to fix (or bypass) all the reported problems in a large codebase but it is worth it.