← back to index

S122 — Statements should be on separate lines

Language: VB.NET  |  Type: CODE_SMELL  |  Severity: Major

Tags: convention

Why is this an issue?

Putting multiple statements on a single line lowers the code readability and makes debugging the code more complex.

Dim a = 0 : Dim b = 0  ' Noncompliant

Write one statement per line to improve readability.

Dim a = 0
Dim b = 0