Commit Graph

84405 Commits

Author SHA1 Message Date
Mikhail Glukhikh bb38eaae61 Postpone OptIn release to version 1.7 2021-07-27 14:56:54 +03:00
Alexander Udalov 0a9498f7e2 Build: suppress deprecated JVM target warning globally
There seems to be no point in configuring the compiler argument per
project. This argument will be deleted soon anyway, when we remove
support for JDK 1.6 & 1.7.

Also remove `disableDeprecatedJvmTargetWarning`. It didn't have any
effect in all modules where it was applied because these modules
reassign `freeCompilerArgs` anyway, with
`-Xsuppress-deprecated-jvm-target-warning` in it.
2021-07-27 13:35:39 +02:00
Alexander Udalov 91c39ed01c Build: remove obsolete compiler arguments
These compiler arguments enable features which are enabled by default in
the current Kotlin anyway.

The only exception is in :compiler:cli which uses an old language
version.
2021-07-27 13:35:38 +02:00
Steffi Stumpos 707e1c7f8d [Test] Add service to provide additional classpath to box tests 2021-07-27 14:05:51 +03:00
Yahor Berdnikau a55eacd8db Migrate Gradle daemon memory leak tests to JUnit5.
^KT-45745 In Progress
2021-07-27 11:43:32 +03:00
Pavel Kunyavskiy be0a0a7784 [K/N] Support escape analysis with new mm 2021-07-27 08:22:02 +00:00
Igor Yakovlev f671061328 [FIR IDE] Add check resolved type for phase less than Types 2021-07-26 23:08:54 +02:00
Igor Yakovlev 02f2f6c148 [FIR IDE] Code review minor changes 2021-07-26 23:08:54 +02:00
Igor Yakovlev 4eb534e39b [FIR IDE] Remove withFirWithPossibleResolve inside function 2021-07-26 23:08:54 +02:00
Igor Yakovlev 563f8c8541 [FIR IDE] Split names of withRef function to phase and type versions 2021-07-26 23:08:54 +02:00
Igor Yakovlev 66fa624ab7 [FIR IDE] Fix IDE return type calculators 2021-07-26 23:08:54 +02:00
Igor Yakovlev 4711577b17 [FIR IDE] Add containing file workaround for FirLightAnonymousClassForSymbol 2021-07-26 23:08:54 +02:00
Igor Yakovlev a4426cd40d [FIR IDE] Fix invalid partial resolve of file annotations 2021-07-26 23:08:54 +02:00
Igor Yakovlev e1c8f302a4 [FIR IDE] Make fir resolve phase volatile and remove locks 2021-07-26 23:08:54 +02:00
Igor Yakovlev 78e249c2d5 [FIR IDE] Fix creating fir light classes for NotUnderContentRootModuleInfo module content 2021-07-26 23:08:53 +02:00
Igor Yakovlev ab2aaec4fe [FIR IDE] Ensure resolve for status transformer 2021-07-26 23:08:53 +02:00
Igor Yakovlev 4e870b6796 [FIR IDE] Fix invalid resolve for fir synthetic properties and accessors 2021-07-26 23:08:53 +02:00
Igor Yakovlev 6700179ee4 [FIR IDE] Add LibraryModuleSourceInfoBase and filter out light classes for sources from libraries 2021-07-26 23:08:53 +02:00
Igor Yakovlev a0418c3146 [STUBS] Fix invalid classId calculation for KtObjectLiteralExpression 2021-07-26 23:08:53 +02:00
Igor Yakovlev 6869fbbfe5 [FIR IDE] Insert ensure resolve into checkers and scopes 2021-07-26 23:08:53 +02:00
Igor Yakovlev 2fd6c55fc8 [FIR IDE] Replace FIR phase update to FIR IDE 2021-07-26 23:08:53 +02:00
Ilya Chernikov df9a3c0300 Restore scripting-ide-services testing, fix coroutines dependency 2021-07-26 21:16:50 +03:00
Ivan Kochurkin 173813f7cf [FIR] Implement REIFIED_TYPE_FORBIDDEN_SUBSTITUTION 2021-07-26 21:13:25 +03:00
Ivan Kochurkin bade6cb611 [FIR] Improve TYPE_PARAMETER_AS_REIFIED detecting, implement TYPE_PARAMETER_AS_REIFIED_ARRAY, TYPE_PARAMETER_AS_REIFIED_ARRAY_WARNING 2021-07-26 21:13:25 +03:00
Ivan Kochurkin 2333b1bcf6 [FIR] Implement BREAK_OR_CONTINUE_JUMPS_ACROSS_FUNCTION_BOUNDARY 2021-07-26 21:13:23 +03:00
Alexander Udalov cbdd0f579a Regenerate Gradle options 2021-07-26 19:36:53 +02:00
Alexander Udalov 0083ef053b Remove Gradle option annotation for -Xbuiltins-from-sources
This is an internal compiler argument for FIR which doesn't seem
valuable enough to be exposed in Gradle, because it'd require to perform
some kind of deprecation if it's changed or removed. It'll still be
possible to use it via `freeCompilerArgs += "-Xbuiltins-from-sources"`.

Note that generated Gradle options are not changed because the generator
was not rerun after adding this compiler argument. (And the test that
checks that the generator was run is failing right now.)
2021-07-26 19:36:53 +02:00
Alexander Udalov fe18e3fa31 Do not use uninterruptible file channels in FileChannelUtil
To avoid illegal access errors from incremental compilation on JDK 16+.

 #KT-45689 Fixed
 #KT-47152 Fixed
2021-07-26 19:27:09 +02:00
Alexander Udalov 2ca241c82c Copy FileChannelUtil from intellij-core
#KT-45689
 #KT-47152
2021-07-26 19:27:09 +02:00
Alexander Udalov 698c0bb2a9 Replace --illegal-access workaround with --add-exports
--illegal-access=permit doesn't work since JDK 17.

 #KT-47152 Fixed
2021-07-26 19:27:09 +02:00
Nikolay Lunyak a44048e713 Add withBindThis to field configuration 2021-07-26 16:12:16 +00:00
Aleksei.Cherepanov 4003cd2832 Fix backward compatibility of portable caches for 212 idea
Write zero to deletedCount value of counters map instead of removing it in context of LookupStorage performance improving
2021-07-26 18:58:12 +03:00
Alexander Shabalin a24eab9745 Fix STMS tests 2021-07-26 15:09:59 +00:00
Alexander Udalov 5526281c54 Minor, refactor diagnostic tests on repeatable annotations 2021-07-26 14:33:32 +02:00
Alexander Udalov 56866e6927 JVM IR: move java.lang.annotation symbols to JvmSymbols.javaAnnotations
Since a separate instance of AdditionalClassAnnotationLowering is
created for each source file, symbols for these classes were created as
many times as there were source files in the module.

Also inline some variables in the process and move around some methods.
2021-07-26 14:33:32 +02:00
Alexander Udalov 50f7594d9e Minor, move RepeatableAnnotationChecker to separate file 2021-07-26 14:33:31 +02:00
Alexander Udalov 104188c035 Render annotation arguments in bytecodeListing tests 2021-07-26 14:33:30 +02:00
Yahor Berdnikau 7958307d28 Allow to override build options for particular builds.
^KT-45745 In Progress
2021-07-26 14:27:47 +02:00
Yahor Berdnikau 25192cd639 Fix project options are ignored for builds.
Fix 'forceOutput' and 'enableGradleDebug' project level options are not
taken into account when running particular build.

^KT-45745 In Progress
2021-07-26 14:27:47 +02:00
Yahor Berdnikau a49b36f6b1 Add additional output assertions.
- check if output contains string exactly times
- check if output does not contain Kotlin warnings
- check expected incremental compilation

^KT-45745 In Progress
2021-07-26 14:27:47 +02:00
Yahor Berdnikau c816d6f2e5 Modify file exists assertion.
Additionally allow to check if file exists in any location, even outside
of the project.

^KT-45745 In Progress
2021-07-26 14:27:47 +02:00
Yahor Berdnikau 18d74e62a6 Add additional shortcuts for common project files.
^KT-45745 In Progress
2021-07-26 14:27:47 +02:00
Yahor Berdnikau 35677f4727 Add random hash to the tempDir project dir.
This will allow to create several similar projects from one resource
project in a single test.

^KT-45745 In Progress
2021-07-26 14:27:46 +02:00
Andrey Zinovyev 8a0941a85a [FIR] Report deprecations in qualified expressions 2021-07-26 14:50:54 +03:00
Mikhail Glukhikh 98bd6f5d3e Fix "implicit type" exception in FIR OptIn checker 2021-07-26 10:13:13 +03:00
Mikhail Glukhikh 2a6355b64c FIR: use coneType instead of coneTypeSafe in OptIn checkers 2021-07-23 23:59:01 +03:00
Mikhail Glukhikh 73539cf342 FIR: use symbols as base for OptIn-checkers 2021-07-23 23:59:00 +03:00
Mikhail Glukhikh cb847b945d FIR: use getAnnotationByClassId instead of getAnnotationByFqName 2021-07-23 23:58:59 +03:00
Mikhail Glukhikh 7cbea12c8a FIR: store all annotationContainers in checker context 2021-07-23 23:58:58 +03:00
Mikhail Glukhikh d020948933 FIR: support EXPERIMENTAL_MARKER_CAN_ONLY_BE_USED_AS_ANNOTATION... 2021-07-23 23:58:57 +03:00