org.sonar.l10n.go.rules.go.S122.html Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sonar-go-plugin Show documentation
Show all versions of sonar-go-plugin Show documentation
SonarQube analyzer for Go language
Why is this an issue?
Putting multiple statements on a single line lowers the code readability and makes debugging the code more complex.
foo(); bar() // Noncompliant
Write one statement per line to improve readability.
foo()
bar()
Exceptions
The rule ignores control flow statements with a single nested statement.
if condition { doSomething() } // Compliant by exception
© 2015 - 2025 Weber Informatics LLC | Privacy Policy