[SR-12063] Swift should warn for switch case '.none' vs '.none?' ambiguity #54499
Labels
compiler
The Swift compiler in itself
diagnostics QoI
Bug: Diagnostics Quality of Implementation
improvement
type checker
Area → compiler: Semantic analysis
Additional Detail from JIRA
md5: 17a3bec14e602d0feaaa8c2f85e8aae7
Issue Description:
With this code:
Everything compiles, but you may have surprising behavior where the `default` case is matched instead of `case .none`.
Following by the example of the great warning you get when you have `let a: Foo? = .none`, it would be great if there was a similar warning for the "ambiguity" here
The text was updated successfully, but these errors were encountered: