SonarQube Java
  1. SonarQube Java
  2. SONARJAVA-150

Rule S00121: if/else/for/while/do statements should always use curly braces

    Details

    • Type: New Feature New Feature
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.3
    • Component/s: None
    • Labels:
      None
    • Number of attachments :
      0

      Description

      http://jira.sonarsource.com/browse/RSPEC-121

      Deprecate checkstyle:com.puppycrawl.tools.checkstyle.checks.blocks.NeedBracesCheck , pmd:ForLoopsMustUseBraces , pmd:IfElseStmtsMustUseBraces , pmd:IfStmtsMustUseBraces and pmd:WhileLoopsMustUseBraces

        Issue Links

          Activity

          Hide
          Fabrice Bellingard added a comment -

          Works well.

          Things to update:

          • rule should be active in default profiles
          • all deprecated rules should be removed from default profiles
          • there's a typo in the code snippet: "Cimpliant" => "Compliant"
          Show
          Fabrice Bellingard added a comment - Works well. Things to update: rule should be active in default profiles all deprecated rules should be removed from default profiles there's a typo in the code snippet: "Cimpliant" => "Compliant"
          Hide
          Evgeny Mandrikov added a comment -

          New rule was already active and old was already marked as deprecated.
          Typo is fixed.

          Show
          Evgeny Mandrikov added a comment - New rule was already active and old was already marked as deprecated. Typo is fixed.
          Hide
          Fabrice Bellingard added a comment -

          Checked!

          Show
          Fabrice Bellingard added a comment - Checked!
          Hide
          Evgeny Mandrikov added a comment -

          Integration tests were updated.

          Show
          Evgeny Mandrikov added a comment - Integration tests were updated.

            People

            • Assignee:
              Evgeny Mandrikov
              Reporter:
              Evgeny Mandrikov
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: