Commit Graph

864 Commits

Author SHA1 Message Date
15716ffd93 [java] SignatureDeclareThrowsException ignores @Override
- Avoid reporting on @Overrides, since we have no control of the
interface.
 - The original definition is still reported if it's part of our
application's code.
 - Fixes #350
2017-06-21 17:50:29 -03:00
2f0e12da6c [java] Fix false positive in UnusedImport
- When referencing static inner members of imports, false positives
would be reported.
 - Fixes #348
2017-06-19 11:07:12 -03:00
135db3f4ce Merge branch 'metrics' of https://github.com/oowekyala/pmd into pr-436 2017-06-16 17:31:20 +02:00
2eb06ada55 Corrections from review #436 2017-06-16 14:21:15 +02:00
e9248b4124 Merge branch 'metrics' of https://github.com/oowekyala/pmd into pr-436 2017-06-16 09:47:26 +02:00
6c7ec75339 Java, typeres: optimize visit(ASTName) by skipping package and import declarations 2017-06-15 00:44:23 +02:00
f57d05d2b3 Merge branch 'pr-423' 2017-06-14 17:41:52 -03:00
41ed666d48 Java, typeres: add field visibility test, fix tests 2017-06-14 18:11:20 +02:00
2291dd2a38 Java, typeres: cleanup non-generic field tests 2017-06-14 14:56:01 +02:00
d53c0c2fe6 Merge branch 'pr-435' 2017-06-12 19:21:05 -03:00
435373faf7 Prefer multicatch for brevity 2017-06-12 19:11:15 -03:00
38447ca3ee PR18522: [java] Fixed false positive for PreserveStackTraceRule when using builder pattern. 2017-06-12 19:00:15 -03:00
0553073208 Merge branch 'pr-426' 2017-06-12 18:11:09 -03:00
7c3e96e02d Update message and description for UnnecessaryFinalModifier 2017-06-12 18:08:26 -03:00
04f72c1509 Added nested class test case 2017-06-12 20:54:58 +02:00
f9095f4480 Use stack in MetricsVisitor 2017-06-12 20:50:14 +02:00
8e495cb5e1 Checkstyle fixes 2017-06-11 16:41:07 +02:00
8e9313791f Completed tests for signatures 2017-06-11 15:51:33 +02:00
0fc9ac185a [java] PMD requires public modifier on JUnit 5 test (fixes #428) 2017-06-11 10:18:12 +02:00
8af4d71940 [java] ImmutableField: False positive with lombok (fixes #410) 2017-06-11 09:07:13 +02:00
a052550130 Reorganised and finished memoization 2017-06-10 19:14:11 +02:00
9eda3d7f96 Visitor tests 2017-06-10 14:51:04 +02:00
919b04166e Untested memoization routines 2017-06-10 02:10:25 +02:00
7fde2478bc Object pooling for Signatures 2017-06-10 01:16:48 +02:00
57c6aadd88 Documentation 2017-06-09 18:40:00 +02:00
0b84366a30 Parse qualified names from string 2017-06-09 17:25:23 +02:00
9b7f2747a3 [java] UnnecessaryFinalModifier final in private method #421
moved from UnnecessaryModifier to UnnecessaryFinalModifier
2017-06-09 15:14:43 +02:00
bfbecd23c6 MetricsVisitor doesn't need a ClassLoader 2017-06-09 14:33:36 +02:00
2b3d12242e Moved toplevel packagestats into metrics 2017-06-09 10:32:01 +02:00
b44b6ab5f6 Made tests for Signature and Sigmask 2017-06-09 10:10:00 +02:00
106c9e4e8b [java] UnnecessaryFinalModifier final in private method #421
tried to fix checkstyle - not sure because this works just on linux
machines I think
2017-06-06 16:00:01 +02:00
28c610d68c [java] UnnecessaryFinalModifier final in private method #421 2017-06-06 15:47:37 +02:00
af328f3e5e Documentation and formatting 2017-06-05 03:53:20 +02:00
a4f3885fcb Implemented hasMatchingSig 2017-06-05 03:35:28 +02:00
c8763bef13 Java: fix typeresolution breaking rules and checkstyle 2017-06-04 00:28:38 +02:00
13025f875d Java: add field access type tests, non-generic is complete 2017-06-04 00:28:38 +02:00
039d4429f9 Java: clear up field access tests 2017-06-04 00:28:38 +02:00
f4ec163385 Java: add field access type resolution, no support for generics 2017-06-04 00:28:38 +02:00
745f2c1d7b Merge branch 'master' into metrics 2017-06-02 23:20:28 +02:00
de72522642 Merge branch 'type-resolution' 2017-06-02 17:55:39 -03:00
1b910587f3 Java: add more tests to this and super expressions 2017-06-02 21:34:24 +02:00
916282be4a Added method to check if QName points to class or op 2017-06-02 11:01:17 +02:00
ca59d3665e Merge branch 'metrics-prework' of https://github.com/oowekyala/pmd into pr-409 2017-06-02 09:33:47 +02:00
0822218574 Simplify expressions 2017-06-01 11:56:48 -03:00
2460402ea8 test case & adapted grammar for annotated generic return type
public static <T> @Nullable T getNullableEnum() {
		return null;
	}
2017-06-01 15:00:20 +02:00
b8d435235f fixed/removed unneeded change
@@ -1488,7 +1488,7 @@ void MethodDeclaration(int modifiers) :
 {jjtThis.setModifiers(modifiers);}
 {
   [ TypeParameters() ]
-  ResultType() MethodDeclarator() [ "throws" NameList() ]
+  [(Annotation() {checkForBadTypeAnnotations();})+] ResultType()
MethodDeclarator() [ "throws" NameList() ]
2017-06-01 10:13:29 +02:00
d40e80742c Java: fix checkstyle issues 2017-05-31 15:59:48 +02:00
455e42bf3b Merge branch 'master' of https://github.com/pmd/pmd into metrics-prework 2017-05-31 11:38:41 +02:00
0ec1e44b13 Java: resolve 'super' expression's type 2017-05-30 20:23:11 +02:00
babe32a16c Java: resolve qualified 'this' expression's type 2017-05-30 17:37:47 +02:00