News for hackers. Stuff that matters.
Re:What’s New in C# 7.0 by ivanca on Thursday August 25, 2016 @05:25AM (#12357795)
Same here, plus I think the parent brakes are noise, can the compiler just know that the switch statement ends on last case?
Re:What’s New in C# 7.0 by 72deluxe on Thursday August 25, 2016 @11:11AM (#12359593)
No, as in some instances you may wish to do the same thing for two case statements, so you need it to fall through case1 into case2.

In other situations, you really don't want it to do that, so a break is required.

How would the compiler know the difference? Note that you can't "fall through" cases in Swift, and it is irritating. It stops you using the same code for two case statements - you have to duplicate it or put it into a function.

Re:What’s New in C# 7.0 by breakingcups on Friday August 26, 2016 @03:04AM (#12364724)
Not with nested switch statements.
Re:What’s New in C# 7.0 by ivanca on Friday August 26, 2016 @11:59PM (#12370896)
...I don't want to ever have to work with your code.