-
Notifications
You must be signed in to change notification settings - Fork 73
Upgrades to Automation for Shared Rule Checking #164
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
jsinglet
merged 27 commits into
github:main
from
jsinglet:jsinglet/automation-check-shared-rules
Jan 17, 2023
Merged
Changes from all commits
Commits
Show all changes
27 commits
Select commit
Hold shift + click to select a range
eb97ecb
finished check
jsinglet 176e9d3
automation
jsinglet 0f64273
more automation
jsinglet 2e9417c
rename
jsinglet 05728db
typo
jsinglet c85ad4e
diagnostics
jsinglet 8a12e42
debugging
jsinglet 591b461
failures
jsinglet dee9091
fix
jsinglet e78b5da
fix
jsinglet aa90e92
paths
jsinglet 78d2ccd
paths
jsinglet e318e4c
test
jsinglet 04fa545
failures
jsinglet 6958753
miss
jsinglet 454833d
failure
jsinglet 2fc4350
fix imported rule
jsinglet 0df6fee
fixes
jsinglet d7936d1
fixes
jsinglet b5f82c0
fixes
jsinglet a331a62
fixes
jsinglet 23f73a9
work
jsinglet a669ecb
work
jsinglet 7f3bbbb
Merge branch 'main' into jsinglet/automation-check-shared-rules
jsinglet 6befae3
fixing tests
jsinglet e450b40
Merge remote-tracking branch 'origin/jsinglet/automation-check-shared…
jsinglet e8b3f1e
Merge branch 'main' into jsinglet/automation-check-shared-rules
jsinglet File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,58 @@ | ||
| name: ⚙️ Extra Rule Validation | ||
|
|
||
| on: | ||
| push: | ||
| branches: | ||
| - main | ||
| - "rc/**" | ||
| - next | ||
| pull_request: | ||
| branches: | ||
| - main | ||
| - "rc/**" | ||
| - next | ||
|
|
||
|
|
||
| jobs: | ||
| validate-rules-csv: | ||
| name: Validate Rules CSV | ||
| runs-on: ubuntu-22.04 | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Check Rules | ||
| shell: pwsh | ||
| run: scripts/util/Get-DuplicateRules.ps1 -Language 'all' -CIMode | ||
|
|
||
|
|
||
| validate-shared-rules-test-structure: | ||
| name: Validate Rules Test Structure | ||
| runs-on: ubuntu-22.04 | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v2 | ||
|
|
||
| - name: Ensure CPP Shared Rules Have Valid Structure | ||
| shell: pwsh | ||
| run: scripts/util/Test-SharedImplementationsHaveTestCases.ps1 -Language cpp -CIMode | ||
|
|
||
| - name: Ensure C Shared Rules Have Valid Structure | ||
| shell: pwsh | ||
| run: scripts/util/Test-SharedImplementationsHaveTestCases.ps1 -Language c -CIMode | ||
|
|
||
|
|
||
| - uses: actions/upload-artifact@v3 | ||
| if: failure() | ||
| with: | ||
| name: missing-test-report.csv | ||
| path: MissingTestReport*.csv | ||
|
|
||
| - uses: actions/upload-artifact@v3 | ||
| if: failure() | ||
| with: | ||
| name: test-report.csv | ||
| path: TestReport*.csv | ||
| if-no-files-found: error | ||
|
|
||
|
|
||
This file was deleted.
Oops, something went wrong.
31 changes: 31 additions & 0 deletions
31
...snottypographicallyunambiguous/DifferentIdentifiersNotTypographicallyUnambiguous.expected
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| | test.c:4:5:4:13 | case1_FOO | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:4:5:4:13 | case1_FOO | case1_FOO | test.c:3:5:3:13 | case1_foo | case1_foo | | ||
| | test.c:4:5:4:13 | case1_FOO | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:4:5:4:13 | case1_FOO | case1_FOO | test.c:5:5:5:13 | case1_fOo | case1_fOo | | ||
| | test.c:5:5:5:13 | case1_fOo | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:5:5:5:13 | case1_fOo | case1_fOo | test.c:3:5:3:13 | case1_foo | case1_foo | | ||
| | test.c:8:5:8:15 | case2_f_o_o | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:8:5:8:15 | case2_f_o_o | case2_f_o_o | test.c:7:5:7:13 | case2_foo | case2_foo | | ||
| | test.c:11:5:11:13 | case3_fO0 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:11:5:11:13 | case3_fO0 | case3_fO0 | test.c:10:5:10:13 | case3_fOO | case3_fOO | | ||
| | test.c:13:5:13:12 | case4_II | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:13:5:13:12 | case4_II | case4_II | test.c:15:5:15:12 | case4_Il | case4_Il | | ||
| | test.c:14:5:14:12 | case4_I1 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:14:5:14:12 | case4_I1 | case4_I1 | test.c:13:5:13:12 | case4_II | case4_II | | ||
| | test.c:14:5:14:12 | case4_I1 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:14:5:14:12 | case4_I1 | case4_I1 | test.c:15:5:15:12 | case4_Il | case4_Il | | ||
| | test.c:18:5:18:11 | case5_5 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:18:5:18:11 | case5_5 | case5_5 | test.c:17:5:17:11 | case5_S | case5_S | | ||
| | test.c:21:5:21:11 | case6_2 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:21:5:21:11 | case6_2 | case6_2 | test.c:20:5:20:11 | case6_Z | case6_Z | | ||
| | test.c:24:5:24:11 | case7_h | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:24:5:24:11 | case7_h | case7_h | test.c:23:5:23:11 | case7_n | case7_n | | ||
| | test.c:27:5:27:11 | case8_8 | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:27:5:27:11 | case8_8 | case8_8 | test.c:26:5:26:11 | case8_B | case8_B | | ||
| | test.c:30:5:30:11 | case9_m | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:30:5:30:11 | case9_m | case9_m | test.c:29:5:29:12 | case9_rn | case9_rn | | ||
| | test.c:31:5:31:12 | case9_rh | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:31:5:31:12 | case9_rh | case9_rh | test.c:29:5:29:12 | case9_rn | case9_rn | | ||
| | test.c:34:5:34:15 | case10_xmmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:34:5:34:15 | case10_xmmx | case10_xmmx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:34:5:34:15 | case10_xmmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:34:5:34:15 | case10_xmmx | case10_xmmx | test.c:35:5:35:16 | case10_xmrnx | case10_xmrnx | | ||
| | test.c:34:5:34:15 | case10_xmmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:34:5:34:15 | case10_xmmx | case10_xmmx | test.c:36:5:36:16 | case10_xrnmx | case10_xrnmx | | ||
| | test.c:35:5:35:16 | case10_xmrnx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:35:5:35:16 | case10_xmrnx | case10_xmrnx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:35:5:35:16 | case10_xmrnx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:35:5:35:16 | case10_xmrnx | case10_xmrnx | test.c:36:5:36:16 | case10_xrnmx | case10_xrnmx | | ||
| | test.c:35:5:35:16 | case10_xmrnx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:35:5:35:16 | case10_xmrnx | case10_xmrnx | test.c:37:5:37:17 | case10_xrnrhx | case10_xrnrhx | | ||
| | test.c:36:5:36:16 | case10_xrnmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:36:5:36:16 | case10_xrnmx | case10_xrnmx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:37:5:37:17 | case10_xrnrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:37:5:37:17 | case10_xrnrhx | case10_xrnrhx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:38:5:38:17 | case10_xrhrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:38:5:38:17 | case10_xrhrhx | case10_xrhrhx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:38:5:38:17 | case10_xrhrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:38:5:38:17 | case10_xrhrhx | case10_xrhrhx | test.c:37:5:37:17 | case10_xrnrhx | case10_xrnrhx | | ||
| | test.c:39:5:39:16 | case10_xmrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:39:5:39:16 | case10_xmrhx | case10_xmrhx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:39:5:39:16 | case10_xmrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:39:5:39:16 | case10_xmrhx | case10_xmrhx | test.c:35:5:35:16 | case10_xmrnx | case10_xmrnx | | ||
| | test.c:39:5:39:16 | case10_xmrhx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:39:5:39:16 | case10_xmrhx | case10_xmrhx | test.c:37:5:37:17 | case10_xrnrhx | case10_xrnrhx | | ||
| | test.c:40:5:40:16 | case10_xrhmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:40:5:40:16 | case10_xrhmx | case10_xrhmx | test.c:33:5:33:17 | case10_xrnrnx | case10_xrnrnx | | ||
| | test.c:40:5:40:16 | case10_xrhmx | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:40:5:40:16 | case10_xrhmx | case10_xrhmx | test.c:36:5:36:16 | case10_xrnmx | case10_xrnmx | | ||
| | test.c:42:15:42:22 | case11_O | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:42:15:42:22 | case11_O | case11_O | test.c:42:5:42:12 | case11_o | case11_o | | ||
| | test.c:45:5:45:14 | case12_8bB | The identifier $@ is not typographically unambiguous from the identifier $@ | test.c:45:5:45:14 | case12_8bB | case12_8bB | test.c:44:5:44:14 | case12_BBb | case12_BBb | |
2 changes: 2 additions & 0 deletions
2
...tifiersnottypographicallyunambiguous/DifferentIdentifiersNotTypographicallyUnambiguous.ql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| // GENERATED FILE - DO NOT MODIFY | ||
| import codingstandards.cpp.rules.differentidentifiersnottypographicallyunambiguous.DifferentIdentifiersNotTypographicallyUnambiguous |
67 changes: 67 additions & 0 deletions
67
c/common/test/rules/differentidentifiersnottypographicallyunambiguous/test.c
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,67 @@ | ||
| // NOTICE: THE TEST CASES BELOW ARE ALSO INCLUDED IN THE C++ TEST CASE AND | ||
| // CHANGES SHOULD BE REFLECTED THERE AS WELL. | ||
| int case1_foo; | ||
| int case1_FOO; // NON_COMPLIANT | ||
| int case1_fOo; // NON_COMPLIANT | ||
|
|
||
| int case2_foo; | ||
| int case2_f_o_o; // NON_COMPLIANT | ||
|
|
||
| int case3_fOO; | ||
| int case3_fO0; // NON_COMPLIANT | ||
|
|
||
| int case4_II; | ||
| int case4_I1; // NON_COMPLIANT | ||
| int case4_Il; // NON_COMPLIANT | ||
|
|
||
| int case5_S; | ||
| int case5_5; // NON_COMPLIANT | ||
|
|
||
| int case6_Z; | ||
| int case6_2; // NON_COMPLIANT | ||
|
|
||
| int case7_n; | ||
| int case7_h; // NON_COMPLIANT | ||
|
|
||
| int case8_B; | ||
| int case8_8; // NON_COMPLIANT | ||
|
|
||
| int case9_rn; | ||
| int case9_m; // NON_COMPLIANT | ||
| int case9_rh; // NON_COMPLIANT | ||
|
|
||
| int case10_xrnrnx; | ||
| int case10_xmmx; // NON_COMPLIANT | ||
| int case10_xmrnx; // NON_COMPLIANT | ||
| int case10_xrnmx; // NON_COMPLIANT | ||
| int case10_xrnrhx; // NON_COMPLIANT | ||
| int case10_xrhrhx; // NON_COMPLIANT | ||
| int case10_xmrhx; // NON_COMPLIANT | ||
| int case10_xrhmx; // NON_COMPLIANT | ||
|
|
||
| int case11_o, case11_O; // NON_COMPLIANT | ||
|
|
||
| int case12_BBb; | ||
| int case12_8bB; // NON_COMPLIANT | ||
|
|
||
| // Transitive rules are compliant | ||
|
|
||
| // m -> rn -> rh | ||
| int case13_m; | ||
| int case13_rh; // COMPLIANT | ||
|
|
||
| // b -> B -> 8 | ||
| int case14_b; | ||
| int case14_8; // COMPLIANT | ||
|
|
||
| // z -> Z -> 2 | ||
| int case15_z; | ||
| int case15_2; // COMPLIANT | ||
|
|
||
| // s -> S -> 5 | ||
| int case16_s; | ||
| int case16_5; // COMPLIANT | ||
|
|
||
| // o -> O -> 0 | ||
| int case17_o; | ||
| int case17_0; |
1 change: 1 addition & 0 deletions
1
...andforgeneratingpseudorandomnumbers/DoNotUseRandForGeneratingPseudorandomNumbers.expected
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| | test.c:5:47:5:50 | call to rand | Use of banned function rand. | |
2 changes: 2 additions & 0 deletions
2
...otuserandforgeneratingpseudorandomnumbers/DoNotUseRandForGeneratingPseudorandomNumbers.ql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| // GENERATED FILE - DO NOT MODIFY | ||
| import codingstandards.cpp.rules.donotuserandforgeneratingpseudorandomnumbers.DoNotUseRandForGeneratingPseudorandomNumbers |
5 changes: 5 additions & 0 deletions
5
c/common/test/rules/donotuserandforgeneratingpseudorandomnumbers/test.c
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| // NOTICE: THE TEST CASES BELOW ARE ALSO INCLUDED IN THE C++ TEST CASE AND | ||
| // CHANGES SHOULD BE REFLECTED THERE AS WELL. | ||
| #include <stdlib.h> | ||
|
|
||
| void test_use_of_rand() { int random_number = rand() % 10; } |
4 changes: 4 additions & 0 deletions
4
c/common/test/rules/hashoperatorsused/HashOperatorsUsed.expected
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,4 @@ | ||
| | test.c:11:1:11:22 | #define MACROFIVE(X) #X | Macro definition uses the # or ## operator. | | ||
| | test.c:13:1:13:26 | #define MACROSIX(X,Y) X ## Y | Macro definition uses the # or ## operator. | | ||
| | test.c:15:1:15:29 | #define MACROSEVEN "##'" #"#" | Macro definition uses the # or ## operator. | | ||
| | test.c:17:1:17:28 | #define MACROEIGHT '##' #"#" | Macro definition uses the # or ## operator. | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| // GENERATED FILE - DO NOT MODIFY | ||
| import codingstandards.cpp.rules.hashoperatorsused.HashOperatorsUsed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,21 @@ | ||
| // NOTICE: THE TEST CASES BELOW ARE ALSO INCLUDED IN THE C++ TEST CASE AND | ||
| // CHANGES SHOULD BE REFLECTED THERE AS WELL. | ||
| #define MACROONE 1 // COMPLIANT | ||
|
|
||
| #define MACROTWO '#' // COMPLIANT | ||
|
|
||
| #define MACROTHREE "##" // COMPLIANT | ||
|
|
||
| #define MACROFOUR "##" + "#" // COMPLIANT | ||
|
|
||
| #define MACROFIVE(X) #X // NON_COMPLIANT | ||
|
|
||
| #define MACROSIX(X, Y) X##Y // NON_COMPLIANT | ||
|
|
||
| #define MACROSEVEN "##'" #"#" // NON_COMPLIANT | ||
|
|
||
| #define MACROEIGHT '##' #"#" // NON_COMPLIANT | ||
|
|
||
| #define MACRONINE "##\"\"" + "#" // COMPLIANT | ||
|
|
||
| #define MACROTEN "##\"\"'" + "#" // COMPLIANT |
3 changes: 3 additions & 0 deletions
3
c/common/test/rules/nonvoidfunctiondoesnotreturn/NonVoidFunctionDoesNotReturn.expected
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| | test.c:8:1:8:1 | return ... | Function test_return_f1 should return a value of type int but does not return a value here | | ||
| | test.c:18:27:18:28 | { ... } | Function test_return_f3 should return a value of type int but does not return a value here | | ||
| | test.c:27:1:27:1 | return ... | Function test_return_f5 should return a value of type int but does not return a value here | |
2 changes: 2 additions & 0 deletions
2
c/common/test/rules/nonvoidfunctiondoesnotreturn/NonVoidFunctionDoesNotReturn.ql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| // GENERATED FILE - DO NOT MODIFY | ||
| import codingstandards.cpp.rules.nonvoidfunctiondoesnotreturn.NonVoidFunctionDoesNotReturn |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| // NOTICE: THE TEST CASES BELOW ARE ALSO INCLUDED IN THE C++ TEST CASE AND | ||
| // CHANGES SHOULD BE REFLECTED THERE AS WELL. | ||
| #include <stdlib.h> | ||
| int test_return_f1(int i) { // NON_COMPLIANT | ||
| if (i > 100) { | ||
| return i; | ||
| } | ||
| } | ||
|
|
||
| int test_return_f2(int i) { // COMPLIANT | ||
| if (i > 0) { | ||
| return i; | ||
| } else { | ||
| return -i; | ||
| } | ||
| } | ||
|
|
||
| int test_return_f3(int i) {} // NON_COMPLIANT | ||
|
|
||
| int test_return_f5(int i) { // NON_COMPLIANT | ||
| if (i > 0) { | ||
| return i; | ||
| } | ||
| if (i < 0) { | ||
| return -i; | ||
| } | ||
| } |
20 changes: 20 additions & 0 deletions
20
.../rules/sectionsofcodeshallnotbecommentedout/SectionsOfCodeShallNotBeCommentedOut.expected
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| | test.c:39:1:39:39 | // int myFunction() { return myValue; } | This comment appears to contain commented-out code. | | ||
| | test.c:41:1:41:45 | // int myFunction() const { return myValue; } | This comment appears to contain commented-out code. | | ||
| | test.c:43:1:43:54 | // int myFunction() const noexcept { return myValue; } | This comment appears to contain commented-out code. | | ||
| | test.c:45:1:45:18 | // #define MYMACRO | This comment appears to contain commented-out code. | | ||
| | test.c:47:1:47:23 | // #include "include.h" | This comment appears to contain commented-out code. | | ||
| | test.c:49:1:53:2 | /*\n#ifdef\nvoid myFunction();\n#endif\n*/ | This comment appears to contain commented-out code. | | ||
| | test.c:61:1:61:24 | // #if(defined(MYMACRO)) | This comment appears to contain commented-out code. | | ||
| | test.c:65:1:65:15 | // #pragma once | This comment appears to contain commented-out code. | | ||
| | test.c:67:1:67:17 | // # pragma once | This comment appears to contain commented-out code. | | ||
| | test.c:69:1:69:19 | /*#error"myerror"*/ | This comment appears to contain commented-out code. | | ||
| | test.c:93:1:97:2 | /*\n#ifdef MYMACRO\n // ...\n#endif // #ifdef MYMACRO\n*/ | This comment appears to contain commented-out code. | | ||
| | test.c:108:21:108:43 | // #include "config2.h" | This comment appears to contain commented-out code. | | ||
| | test.c:114:16:114:35 | /* #ifdef MYMACRO */ | This comment appears to contain commented-out code. | | ||
| | test.c:118:1:118:24 | // commented_out_code(); | This comment appears to contain commented-out code. | | ||
| | test.c:121:2:121:25 | // commented_out_code(); | This comment appears to contain commented-out code. | | ||
| | test.c:124:1:124:22 | // commented out code; | This comment appears to contain commented-out code. | | ||
| | test.c:126:1:129:8 | // some; | This comment appears to contain commented-out code. | | ||
| | test.c:131:1:135:8 | // also; | This comment appears to contain commented-out code. | | ||
| | test.c:143:1:148:2 | /*\n some;\n commented;\n out;\n code;\n*/ | This comment appears to contain commented-out code. | | ||
| | test.c:150:1:156:2 | /*\n also;\n this\n is;\n commented-out\n code;\n*/ | This comment appears to contain commented-out code. | |
2 changes: 2 additions & 0 deletions
2
...n/test/rules/sectionsofcodeshallnotbecommentedout/SectionsOfCodeShallNotBeCommentedOut.ql
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| // GENERATED FILE - DO NOT MODIFY | ||
| import codingstandards.cpp.rules.sectionsofcodeshallnotbecommentedout.SectionsOfCodeShallNotBeCommentedOut |
Empty file.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.