Hi
Looks like the new pattern matching feature broke old style switch expression
https://github.com/rds1983/StbImageSharp/blob/master/src/StbImageSharp/PngDecoder.cs#L714
Doesn't compile anymore
PngDecoder.cs(714, 38): [CS1003] Syntax error, ':' expected
PngDecoder.cs(714, 70): [CS1002] ; expected
PngDecoder.cs(714, 70): [CS1513] } expected
PngDecoder.cs(718, 39): [CS1003] Syntax error, ',' expected
PngDecoder.cs(774, 39): [CS1003] Syntax error, ',' expected
PngDecoder.cs(793, 39): [CS1003] Syntax error, ',' expected
PngDecoder.cs(842, 39): [CS1003] Syntax error, ',' expected
PngDecoder.cs(878, 39): [CS1003] Syntax error, ',' expected
@gafter @jaredpar Does this belong in dotnet/roslyn?
@gafter can you verify this is a dupe of the switch bugs you've already fixed?
@jaredpar I do not believe this has been fixed
Looks like a dupe for https://github.com/dotnet/roslyn/issues/33208
Fixed in https://github.com/dotnet/roslyn/pull/33279 for dev16.0
As a workaround, declare a named local constant to hold the constant value you are using for the switch case.
Most helpful comment
Fixed in https://github.com/dotnet/roslyn/pull/33279 for dev16.0