Commit Graph

828 Commits

Author SHA1 Message Date
af328f3e5e Documentation and formatting 2017-06-05 03:53:20 +02:00
a4f3885fcb Implemented hasMatchingSig 2017-06-05 03:35:28 +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
1a6be9190b + beautified method signature 2017-05-30 16:09:17 +02:00
0aff989862 Checkstyle fix 2017-05-30 15:36:39 +02:00
9ee19ac7ac Remove ALL fields in enums 2017-05-30 15:29:25 +02:00
a4754e9fc9 I hear voices ... and they tell me to like multi dimensional arrays
private static void testMultiDimArrayWithAnnotations() {
		// ever used a 2D-Array in java??
		Object x = new Object @NonNull[2] @Nullable[1] @NonNull[3];
	}
2017-05-30 15:15:44 +02:00
c543cef8b1 Big refactor of qname
The creation methods now mostly take the node to describe as parameter. That way, the implementation of the class is less exposed, the creation methods can be overloaded and simplified in the AST nodes' classes.

Only nested class do not do that. That is to keep the recursive call to getQualifiedName which would be much more complicated if it was called from QualifiedName rather than the AST node.
2017-05-30 15:15:10 +02:00
3e75ddc188 + should have tried first :( 2017-05-30 14:59:53 +02:00
5120b0985c fixed bad void return 2017-05-30 14:58:09 +02:00
7997297e0b test case for
public void createNonNullArray() {
		return new MetaColumn @NonNull [value];
	}
2017-05-30 14:13:38 +02:00
b5474cdcf8 test case and fix for
public static <T extends @NonNull Enum<T>> getEnum() {
		return null;
	}
2017-05-30 14:05:29 +02:00
02bac9ab71 Moved QualifiedName into standalone class 2017-05-30 13:34:48 +02:00
0660c7298a + simplified 2017-05-30 12:31:03 +02:00
d314a2c301 test case for
private byte @Nullable [] getBytes(){
		return null;
	}
2017-05-30 12:20:26 +02:00
7a4766e8a6 [java] Parsing Problem with Annotation for Array Member Types #417 2017-05-30 10:52:09 +02:00
68ab7048cb *[java]* Java 8 parsing problem with annotations for wildcards #414 2017-05-29 18:20:12 +02:00
6fb5681734 Resolve 'this' keyword in Java 2017-05-29 02:47:21 +02:00
e75cf1b55c Add test for Java 'this' keyword typeresolution 2017-05-29 02:29:13 +02:00
7ef9b93b90 Add method reference test case 2017-05-26 14:24:24 -03:00
e1f02acf87 Checkstyle fix 2017-05-26 17:56:09 +02:00
6fbcb431fc Checkstyle fixes 2017-05-26 17:45:21 +02:00
0847f24068 Fix capabilities nonsense 2017-05-26 15:13:03 +02:00
5b918ba53d Revert "Canonical type of arguments in method Qname" until TypeRes is ok 2017-05-26 14:59:46 +02:00
b09cde6d03 Canonical type of arguments in method Qname\n That doesn't work for now because of Typeres. Be sure to edit the tests 2017-05-26 14:56:49 +02:00
909bb60043 Inlined canonical separators for qualified names 2017-05-26 14:45:17 +02:00
1673e8306a Use Qname for memoized result retrieval 2017-05-26 14:25:00 +02:00
43c13b4c8c Merge branch 'master' into PR18700 2017-05-26 10:26:19 +02:00
a6185327b5 Qualified names memoization 2017-05-25 20:08:43 +02:00
5f426f90b7 Removed probably useless methods from QualifiedName 2017-05-23 22:10:44 +02:00
def31ec49c Documentation 2017-05-23 22:09:28 +02:00
5b622e6cf5 hashCode and equals for Signatures 2017-05-23 21:36:04 +02:00
f83ee39c65 Visitor with classContext 2017-05-23 21:25:31 +02:00
c35e513598 Static building method for FieldSignature 2017-05-23 21:24:52 +02:00
a50a1b5795 Revert "FieldDeclaration implements QualifiableNode"
This reverts commit ded6dc670b.
2017-05-23 21:20:05 +02:00
ded6dc670b FieldDeclaration implements QualifiableNode 2017-05-23 21:18:20 +02:00
a99f0c276d Added modification methods for ClassStats 2017-05-23 20:49:00 +02:00
e4392fc751 createIfNotFound for PackageStats methods 2017-05-23 20:29:54 +02:00
5607456f2f Simplified existing metrics 2017-05-23 17:59:22 +02:00