File tree Expand file tree Collapse file tree 3 files changed +16
-20
lines changed
java/ql/test/query-tests/EmptyMethod Expand file tree Collapse file tree 3 files changed +16
-20
lines changed Original file line number Diff line number Diff line change 1- | Test.java:16:17:16:18 | f2 | Empty method found. |
1+ | Test.java:13:15:13:16 | f2 | Empty method found. |
Original file line number Diff line number Diff line change 1- Language Abuse/EmptyMethod.ql
1+ query: Language Abuse/EmptyMethod.ql
2+ postprocess: utils/test/InlineExpectationsTestQuery.ql
Original file line number Diff line number Diff line change 22
33public class Test {
44
5- // COMPLIANT
6- public void f () {
7- int i = 0 ;
8- }
5+ public void f () {
6+ int i = 0 ;
7+ }
98
10- // COMPLIANT
11- public void f1 () {
12- // intentionally empty
13- }
9+ public void f1 () {
10+ // intentionally empty
11+ }
1412
15- // NON_COMPLIANT
16- public void f2 () {}
13+ public void f2 () { } // $ Alert
1714
18- // COMPLIANT - exception
19- @ Pointcut ()
20- public void f4 () { }
15+ @ Pointcut ()
16+ public void f4 () {
17+ }
2118
22- public abstract class TestInner {
19+ public abstract class TestInner {
2320
24- public abstract void f (); // COMPLIANT - intentionally empty
25- }
21+ public abstract void f ();
22+ }
2623
2724}
28-
29-
You can’t perform that action at this time.
0 commit comments