File tree Expand file tree Collapse file tree 2 files changed +35
-1
lines changed
c/common/test/rules/identifierhidden Expand file tree Collapse file tree 2 files changed +35
-1
lines changed Original file line number Diff line number Diff line change 1
- No expected results have yet been specified
1
+ | test.c:4:7:4:9 | id1 | Variable is hiding variable $@. | test.c:1:5:1:7 | id1 | id1 |
2
+ | test.c:7:13:7:15 | id1 | Variable is hiding variable $@. | test.c:1:5:1:7 | id1 | id1 |
3
+ | test.c:10:12:10:14 | id1 | Variable is hiding variable $@. | test.c:1:5:1:7 | id1 | id1 |
4
+ | test.c:11:14:11:16 | id1 | Variable is hiding variable $@. | test.c:10:12:10:14 | id1 | id1 |
5
+ | test.c:24:24:24:26 | id2 | Variable is hiding variable $@. | test.c:22:5:22:7 | id2 | id2 |
Original file line number Diff line number Diff line change
1
+ int id1 ;
2
+
3
+ void f1 () {
4
+ int id1 ; // NON_COMPLIANT
5
+ }
6
+
7
+ void f2 (int id1 ) {} // NON_COMPLIANT
8
+
9
+ void f3 () {
10
+ for (int id1 ; id1 < 1 ; id1 ++ ) { // NON_COMPLIANT
11
+ for (int id1 ; id1 < 1 ; id1 ++ ) {
12
+ } // NON_COMPLIANT
13
+ }
14
+ }
15
+
16
+ struct astruct {
17
+ int id1 ;
18
+ };
19
+
20
+ extern void g (struct astruct * p );
21
+
22
+ int id2 = 0 ;
23
+
24
+ void f4 (struct astruct id2 ) { // NON_COMPLIANT
25
+ g (& id2 );
26
+ }
27
+
28
+ void f5 (struct astruct id3 ) { // COMPLIANT
29
+ g (& id2 );
30
+ }
You can’t perform that action at this time.
0 commit comments