File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed
test/java/org/sonar/cxx/sensors/cppcheck Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -2753,6 +2753,23 @@ const reference which is usually faster and recommended in C++.
2753
2753
</p>
2754
2754
<h2>References</h2>
2755
2755
<p><a href="https://cwe.mitre.org/data/definitions/398.html" target="_blank">CWE-398: 7PK - Code Quality</a></p>
2756
+ ]]>
2757
+ </description >
2758
+ <tag >cwe</tag >
2759
+ <severity >MINOR</severity >
2760
+ <type >BUG</type >
2761
+ </rule >
2762
+ <rule >
2763
+ <key >iterateByValue</key >
2764
+ <name >Range variable 'var' should be declared as const reference</name >
2765
+ <description >
2766
+ <![CDATA[
2767
+ <p>
2768
+ Variable 'var' is used to iterate by value. It could be declared as a
2769
+ const reference which is usually faster and recommended in C++.
2770
+ </p>
2771
+ <h2>References</h2>
2772
+ <p><a href="https://cwe.mitre.org/data/definitions/398.html" target="_blank">CWE-398: 7PK - Code Quality</a></p>
2756
2773
]]>
2757
2774
</description >
2758
2775
<tag >cwe</tag >
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ void createRulesTest() {
37
37
def .define (context );
38
38
39
39
RulesDefinition .Repository repo = context .repository (CxxCppCheckRuleRepository .KEY );
40
- assertThat (repo .rules ()).hasSize (687 );
40
+ assertThat (repo .rules ()).hasSize (688 );
41
41
}
42
42
43
43
}
You can’t perform that action at this time.
0 commit comments