Commit Graph

15 Commits

Author SHA1 Message Date
Denis Zharkov
f6c6f67566 Minor. Remove irrelevant JAVAC_EXPECTED_FILE directive in tests
This change fixes these tests
2018-02-09 10:54:28 +03:00
Denis Zharkov
88a23c73c7 Ignore @Nullable annotation for vararg parameter
See the comment in code for clarification

 #KT-19786 Fixed
2018-02-08 13:36:10 +03:00
Denis Zharkov
da52716bfd Fix wrong nullability enhancement for annotated java.lang.Object type
Effectively, this commit drops cached value for j.l.Object type
This cache was introduced when types were immutable, but they
became mutable after starting reading top-level TYPE_USE annotations,
that lead to changing shared JAVA_LANG_OBJECT_CLASSIFIER_TYPE instance

 #KT-20826 Fixed
2017-10-20 09:43:38 +03:00
Denis Zharkov
13bf35f48e Make TYPE_USE default qualifiers overriding all other applicabilities
If there is default qualifier with TYPE_USE closer than one with METHOD
then its nullability should be considered even when enhancing return type

 #KT-20016 Fixed
2017-09-29 10:01:04 +03:00
Denis Zharkov
fd9025a4fb Add Java8 foreign-annotations tests without jsr305.jar in the classpath
Some of them are expected to fail since neither IntelliJ class reading
nor our fast class reading can read annotations on type arguments
2017-09-26 16:40:47 +03:00
Denis Zharkov
58a0ca61a9 Minor. Fix java test data to make it actually compilable 2017-09-26 16:40:47 +03:00
Denis Zharkov
71f85812d6 Improve support for TYPE_USE default qualifiers
- Apply default qualifiers to type arguments if they contain TYPE_USE
in applicability list
- Read TYPE_USE placed default qualifier annotations

 #KT-19592 Fixed
 #KT-20016 In Progress
2017-09-26 16:40:47 +03:00
Denis Zharkov
02d3d9785c Move JSR-305 tests to one directory and strip common name prefix 2017-09-26 16:40:47 +03:00
baratynskiy
01883a41cb javac-wrapper: refactoring, fixes and tests 2017-08-29 18:01:36 +03:00
Denis Zharkov
e26c210d69 Support TypeQualifierDefault from JSR 305 for nullability qualifiers
#KT-10942 Fixed
2017-07-03 17:55:37 +03:00
Denis Zharkov
57b7b91444 Do not add container annotaions to type artificially
It was only used for type-related nullability/mutability
annotations and it was necessary to remove them
in the descriptor renderer (duplicating their fqnames there).
At the same time they're only needed for types enhancement
where they can be simply restored from type owners' descriptors

The testData changes are more or less correct: this kind of annotations
is bound both to types themselves and their use because of their targets
2017-07-03 17:55:37 +03:00
Valentin Kipyatkov
ec51076355 DescriptorRenderer to render annotations for all types + separate option to render annotation arguments + use it in IdeDescriptorRenderers 2016-10-11 23:38:54 +03:00
Denis Zharkov
10c840327d Temporary move annotation to methods' modifier list
Java resolver ignores return type annotations if there are ones on modifier list

Related to this commit a2497edcee
2016-09-20 15:26:50 +03:00
Denis Zharkov
e96024017f Move and fix tests on typeEnhancement with TYPE_USE annotations 2016-03-16 20:22:59 +03:00
Denis Zharkov
a644dd3ae9 Create tests for TYPE_USE nullability annotations
- tests and declarations for checkerframework has been moved,
because they only Java 8 targeted
- tests for eclipse annotations has been just copied,
because there are two jars: one for Java 8 and other for earlier versions
2016-03-16 20:22:59 +03:00