Commit Graph

42 Commits

Author SHA1 Message Date
Dmitriy Novozhilov 1f6ce874a1 Don't fail on unsupported default values of java annotations 2021-03-05 13:00:12 +03:00
Alexander Udalov f63ffc51ae Remove JvmBytecodeBinaryVersion from the compiler code
Move it to build-common where it's still used in incremental compilation
caches, and simplify a bit. In the future, it'll make sense to remove it
completely and to avoid writing it to caches. In this commit, I don't do
that to prevent the IC cache version to be updated, causing rebuilds for
all JPS projects.

 #KT-41758
2021-02-23 12:45:41 +01:00
Alexander Udalov 862a9143da Do not report errors about bytecode version
#KT-41758
2021-02-23 12:45:40 +01:00
Denis.Zharkov 893b1045ba Move some common parts from BuiltinMethodsWithDifferentJvmName to SpecialGenericSignatures 2021-02-20 10:59:21 +03:00
Alexander Udalov 3432f581cb Remove compiler support for kotlin-annotations-android
#KT-44815
2021-02-15 17:23:44 +01:00
Alexander Udalov e0b6d4d917 Add -Xsuppress-deprecated-jvm-target-warning to modules compiled with 1.6
Currently this leads to an unknown argument warning, but it'll be
removed automatically on the next bootstrap.
2021-02-03 12:51:39 +01:00
Alexander Udalov 3f517d7e8d Add new metadata flag for class files compiled with FIR
Report a separate error when class files compiled with FIR are in
dependencies, in addition to the one for class files compiled with FE
1.0 + JVM IR.

 #KT-43592
2020-12-20 23:14:30 +01:00
Victor Petukhov 48d9812d9e Review fixes around type enhancement and loading type use annotations 2020-12-18 19:32:05 +03:00
Victor Petukhov d6017420de Mark freshly supported annotations to use that mark for reporting corresponding warnings 2020-12-18 19:32:05 +03:00
Victor Petukhov 857cc92326 Support preference of TYPE_USE annotations to enhance over others like METHOD, FIELD and VALUE_PARAMETER to avoid double applying them in case of arrays: @NotNull Integer [] (both to the array element and to the entire array)
^KT-24392 Fixed
2020-12-18 19:32:04 +03:00
Victor Petukhov a89329e077 Support reading from class files of the type use annotations on type parameters and type arguments
^KT-11454 Fixed
2020-12-18 19:32:03 +03:00
Dmitriy Novozhilov bdfb71b149 [FE] Add sealed classes related properties to java model 2020-12-09 22:54:28 +03:00
Denis.Zharkov 513f7177ca Support loading Java records
^KT-43677 In Progress
2020-12-09 16:29:03 +03:00
Mikhail Glukhikh f866eff93e Extract special generic signatures to compiler.common.jvm to reuse in FIR 2020-10-23 08:12:15 +03:00
Victor Petukhov 8974128be4 JSpecify: remove annotations unsupported yet 2020-10-12 17:24:27 +03:00
Victor Petukhov 9f716ba37c Jspecify: Rename DefaultNotNull to DefaultNonNull 2020-10-08 14:00:10 +03:00
Victor Petukhov c3bada44cf Jspecify: Rename NullnessUnknown to NullnessUnspecified 2020-10-08 14:00:10 +03:00
Victor Petukhov 2685c7efce Jspecify: Rename codeanalysis annotations to jspecify ones 2020-10-08 14:00:10 +03:00
Denis Zharkov 59bd7364ab Enhance bounds for type parameters after loops disconnection
Otherwise behavior might change because enhancement may force computation
for other type parameters in cases like:
class A<X extends Y, Y extends X> {}

See the test:
org.jetbrains.kotlin.checkers.DiagnosticsTestGenerated.Tests.J_k#testRecursiveRawUpperBound3
2020-10-08 14:00:10 +03:00
Denis Zharkov f3a490ee16 Support compiler flag -Xcodeanalysis-annotations 2020-10-08 14:00:09 +03:00
Denis Zharkov 392ef9aa2b Support type arguments enhancement from type parameters bounds
Currently, only works for codeanalysis annotations because
type parameters bounds are enhanced only for them
2020-10-08 14:00:07 +03:00
Denis Zharkov e9e05c53e1 Support enhancement for type parameter based types
Load them as non-flexible when a relevant type parameter has non-flexible upper bound
(Currently, it only works for case of codeanalysis annotations)
2020-10-08 14:00:07 +03:00
Denis Zharkov fa2578c795 Prepare type enhancement for codeanalysis annotations
- Rename NullabilityQualifierWithApplicability -> JavaDefaultQualifiers
- Use JavaDefaultQualifiers instead of JavaTypeQualifiers for default qualifiers

This change is intended to make code more clear and to allow add some additional
parameters specific for default qualifiers needed for codeanalysis annotations
2020-10-08 14:00:07 +03:00
Denis Zharkov e27501497b Support codeanalysis annotations on type parameters bounds 2020-10-08 14:00:06 +03:00
Denis Zharkov 82d39dd86a Add basic support for default codeanalysis annotations 2020-10-08 14:00:06 +03:00
Denis Zharkov 517cc84f4d Add initial support for codeanalysis annotations 2020-10-08 14:00:06 +03:00
Denis Zharkov 5cc12b49fc Hide java.lang.CharSequence::isEmpty from Kotlin built-in class
Also, prohibit using it as a synthetic property

^KT-42467 In progress
2020-10-07 17:48:19 +03:00
Denis Zharkov 90044f9672 Use correct naming for additional built-in member lists 2020-10-07 17:48:19 +03:00
Denis Zharkov 9914b487b7 FIR: Do not load hashCode/toString/equals methods from Java interface
As it's done in FE 1.0, and there are subtle semantics in the language that depends on it
2020-10-01 17:49:02 +03:00
Dmitriy Novozhilov 86d4d320c4 Introduce AbstractTypeMapper based on type markers 2020-09-24 16:51:06 +03:00
Dmitriy Novozhilov c3a89e2507 Move common part of typeSignatureMapping.kt to :core:compiler.common.jvm 2020-09-24 16:51:05 +03:00
Dmitriy Novozhilov d215c413cc Move TypeMappingMode to :core:compiler.common.jvm 2020-09-24 16:51:05 +03:00
Dmitriy Novozhilov 9e1e525343 Fix circular dependency between :core:compiler:common.jvm and :core:metadata.jvm 2020-09-11 10:08:36 +03:00
Dmitriy Novozhilov 1417fcecb8 Move more common parts from :compiler:descriptors.jvm 2020-09-11 10:08:36 +03:00
Dmitriy Novozhilov 6906e0d82d Move common jvm classes from :core:descriptors.jvm to :core:compiler.common.jvm 2020-09-04 11:42:51 +03:00
Dmitriy Novozhilov 9806a85cc1 Move Java model classes to :core:compiler.common.jvm 2020-09-04 11:42:51 +03:00
Dmitriy Novozhilov 696f089b3e Make DescriptorVisibility delegate to Visibility 2020-09-04 11:42:50 +03:00
Dmitriy Novozhilov a05d6da43b Move descriptor-independent Visibilities to common modules 2020-09-04 11:42:50 +03:00
Dmitriy Novozhilov 64ec3fc42b Move BuiltinSpecialProperties and JvmAbi to :core:compiler.common.jvm 2020-09-04 11:07:41 +03:00
Dmitriy Novozhilov 10fd164b77 Extract FE 1.0 dependent part from JavaToKotlinClassMap
Also move JavaToKotlinClassMap to :core:compiler.common.jvm
2020-09-04 11:07:41 +03:00
Dmitriy Novozhilov 136435bcc2 Move JvmPrimitiveType to :core:compiler.common 2020-09-04 11:07:41 +03:00
Dmitriy Novozhilov 564d382b9d Introduce new modules for common jvm related parts of compiler 2020-09-04 11:07:40 +03:00