Then tell us:
- What language is this for?
Swift
- Which rule?
The return value of xxx must be used
- Why do you believe it’s a false-positive/false-negative?
A switch statement in swift return a value implicitly since the latest release
- Using
SonarCloud
- How can we reproduce the problem? Give us a self-contained snippet of code (formatted text, no screenshots)
enum MyEnum {
case myCase
var sonarCloudProblem: String {
switch self {
case myCase:
"Hello".uppercased()
}
}
}