Commit Graph

2906 Commits

Author SHA1 Message Date
Pavel Mikhailovskii 6a14400342 KT-53804 Restore old and incorrect logic of generating InnerClasses attributes for kotlin-stdlib 2022-09-05 14:02:52 +00:00
Alexander Korepanov 453faeaa45 [JS IR] Memory consumption optimization
- Remove IR after JS AST generation
 - Remove JS AST after/during JS code generation
2022-09-05 11:15:55 +00:00
Alexander Udalov 13ca189825 Support -Xjdk-release=8 as alias for -Xjdk-release=1.8
#KT-53278 Fixed
2022-09-01 12:15:47 +02:00
Alexander Udalov a76de14026 Remove obsolete compiler argument -Xsingle-module
#KT-51622
2022-08-31 20:54:50 +02:00
Mikhael Bogdanov bd6aff7f6a Xjdk-release: avoid folder duplication 2022-08-29 12:26:27 +00:00
Dmitry Gridin 924dd38144 [lc] introduce KotlinAsJavaSupportBase with new common facade logic
^KT-53543
2022-08-29 11:51:42 +00:00
Alexander Udalov 690322b203 Add flag -Xno-new-java-annotation-targets
Do not generate TYPE_USE/TYPE_PARAMETER Java annotation targets when
this flag is specified.

 #KT-53712 Fixed
2022-08-29 13:43:49 +02:00
Nikita Bobko 2a4f3f41aa 2/5 Replace source dependency on kotlin-reflect with binary dependency
Review: https://jetbrains.team/p/kt/reviews/6753

Meaningful semantic change was splitted into 5 commits to simplify the
change review. Sinle commit would be too big.

Why replace source to binary: to get rid of kotlin-reflect in Kotlin
plugin artifact KTIJ-22276

Note: Kotlin Maven artifacts (./gradlew publish) changed their
dependency on kotlin-reflect
2022-08-22 15:43:49 +02:00
Nikita Bobko 0874fb71c6 Replace all kotlin-reflect-api dependencies with kotlin-reflect
Review: https://jetbrains.team/p/kt/reviews/6753

Why: I'm going to replace source dependency on kotlin-reflect with
binary dependency. Normalize reflect dependency before global
processing.
2022-08-22 15:43:11 +02:00
Dmitriy Novozhilov f843883985 [FE 1.0] Introduce AssignResolutionAltererExtension
This extension can be used to override resolution of assign statements
  with custom logic

WARNING: there is no compatibility guarantees for this extension
2022-08-19 07:44:08 +00:00
Ivan Kylchik 3027ea9551 Add new jvm compilation key ignoreConstOptimizationErrors
This key suppose to be a workaround in keys if something goes
wrong in ir interpreter.
2022-08-18 16:50:06 +00:00
Alexander Udalov 45abea5b0a Use platform class loader in 'kotlin' runner on JDK 9+
#KT-46312 Fixed
2022-08-17 22:23:10 +02:00
Andrey Uskov 339868305e Fixed handling of special symbols in paths when reporting errors
#KT-53246 Fixed
2022-08-17 10:38:28 +04:00
Aleksei.Cherepanov df017ea187 Clean JavaClassesTracker and LookupTracker on call RetryWithAdditionalRoots
#KT-38576 Fixed
2022-08-16 14:38:01 +00:00
Abduqodiri Qurbonzoda 983c7adb1e Remove :libraries:tools:stdlib-compiler-classpath project
It was used as a workaround to allow jvmTarget=1.6 in stdlib.
2022-08-13 01:42:43 +03:00
Jiaxiang Chen 94abeb64c5 use top level classId for looking up java classes in KotlinCliJavaFileManagerImpl 2022-08-12 14:24:13 +02:00
Artem Kobzar 87038e7d8a [K/JS] feat: add logic under the flag for strict implicit export generating inside d.ts files. 2022-08-09 16:48:59 +00:00
Igor Chevdar 030e3b306f [K/N][build] Added -Xmake-per-file-cache compiler option 2022-08-06 17:40:24 +00:00
Igor Chevdar 7e79b2b500 [K/N][IR][codegen] Preliminary support of per-file caches 2022-08-06 17:40:23 +00:00
Aleksei.Cherepanov 92551b7685 Prevent overwriting output dir to empty string
#KTIJ-921 Fixed

Co-authored-by: Alexander Udalov <Alexander.Udalov@jetbrains.com>

Merge-request: KT-MR-6183
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2022-08-03 14:46:32 +00:00
Victor Petukhov 9beb279964 [FE CLI] Remove -Xnew-inference in the compiler cli module settings 2022-08-02 10:29:40 +00:00
Mikhael Bogdanov 90f8f8e14e Support inner classes in -Xjdk-release
#KT-52823 Fixed
2022-08-02 04:56:20 +00:00
Ivan Kochurkin 2f56b29b3f [FIR] Extract FirSessionConfigurator and IncrementalCompilationContext to separated classes
With FirSessionFactory and FirJsSessionFactory
2022-07-25 23:30:09 +02:00
Sergey Bogolepov cd54afea8f [K/N] Add option to omit generation of binary when producing framework
`-Xomit-framework-binary` is useful when the user does not care about
generated machine code, but only about its public interface.
Current use-case is for development purposes only: to iterate faster
on ObjCExport. But potentially it can be turned into user-facing feature
2022-07-22 11:57:15 +00:00
Mikhail Glukhikh 9add6f3d55 K2: add more accurate & more automatic control of diagnostic suppression
#KT-51363 Fixed
2022-07-22 11:35:26 +00:00
Sergej Jaskiewicz 9bc057afb2 [JS IR] Generate the correct relative paths in source maps 2022-07-21 12:18:45 +00:00
Dmitriy Novozhilov b2e558a174 [CLI] Make -Xcompiler-plugin experimental and K2 only 2022-07-20 09:07:27 +00:00
Dmitriy Novozhilov 928416c9c5 [CLI] Introduce new compiler arguments for registering compiler plugins
With new syntax each plugin should be registered in separate argument with syntax
`-Xcompiler-plugin=classpath1,classpath2[=argument1=value1,argument2=value2]`
2022-07-20 09:07:26 +00:00
Dmitry Gridin 0e17d9b452 [light classes] extract KotlinLightClassFactory to service
^KT-53097
2022-07-19 15:42:07 +00:00
Dmitry Gridin e5519064f4 [light classes] move script creation logic to KotlinLightClassFactory
^KT-53097
2022-07-19 15:41:45 +00:00
Dmitry Gridin dc552c9fe3 [light classes] move facade creation logic to KotlinLightClassFactory
^KT-53097
2022-07-19 15:41:44 +00:00
Dmitry Gridin 9510c4876c [light classes] introduce KotlinLightClassFactory
^KT-53097
2022-07-19 15:41:43 +00:00
Dmitry Gridin 47fa444792 [light classes] move descriptors from KtLightClassForSourceDeclaration to KtLightClassImpl
^KT-53097
2022-07-19 15:41:36 +00:00
Yahor Berdnikau 93a0cdbf97 Improve warnings and errors emitted by compiler in Gradle build
Make warnings and errors location clickable by using file URI scheme.
In most terminals and code editors (including IDEA) clicking on such uri
will open file at given line and offset.

^KT-51923 Fixed
2022-07-19 09:30:36 +00:00
Yahor Berdnikau 603d043abc Move Kotlin/Native compiler arguments into :compiler:cli:cli-common
This allows to reference them in the Gradle plugins without enabling
kotlin-native part of the repository

^KT-53108 In Progress
2022-07-14 10:57:28 +00:00
Denis.Zharkov f7a2889a40 FastJarHandler: Add information for exceptions thrown during CD parsing
^KT-52786 Related
2022-07-12 14:45:37 +00:00
Nikita Nazarov 2ab92bcb7e Add a key to enable spilling of all variables in a suspending context
This commit adds a new key that will allow users to enhance their
debugging experience in suspending contexts when using the IR backend.
After the key is enabled, the following things are changed:
1. All variables in a suspending context are spilled regardless their
liveness.
2. Their LVT records are not shrunk.
3. ACONST_NULL is not spilled to dead variables.

#KT-48678 In progress

(cherry picked from commit 38d97d0621)
2022-07-07 14:51:24 +03:00
Nikolay Krasko c6299ee277 Revert "Add a key to enable spilling of all variables in a suspending context"
This reverts commit 38d97d0621.
2022-07-05 11:04:50 +00:00
Nikita Nazarov 38d97d0621 Add a key to enable spilling of all variables in a suspending context
This commit adds a new key that will allow users to enhance their
debugging experience in suspending contexts when using the IR backend.
After the key is enabled, the following things are changed:
1. All variables in a suspending context are spilled regardless their
liveness.
2. Their LVT records are not shrunk.
3. ACONST_NULL is not spilled to dead variables.

#KT-48678 In progress
2022-07-02 18:29:18 +03:00
Dmitriy Novozhilov 1a8496757e [Compiler] Mark all entrypoints to compiler API as experimental 2022-06-29 12:00:01 +00:00
Dmitriy Novozhilov 65e240679e [FE] Move utility of parsing plugin options to :compiler:frontend.common
This is needed to be able to use this utility inside FIR part of IDE plugin
2022-06-29 12:00:00 +00:00
Dmitriy Novozhilov f587c02d38 [FE] Move ServiceLoaderLite to :compiler:frontend.common
This is needed to be able to use this class inside FIR part of IDE plugin
2022-06-29 12:00:00 +00:00
Dmitriy Novozhilov c979e1edcf [Plugins] Deprecate ComponentRegistrar
^KT-52665 In Progress
2022-06-29 11:59:58 +00:00
Dmitriy Novozhilov 8b42638afa [Plugins] Introduce new API for registering compiler plugins
Original `ComponentRegistrar` exposes Project to its registration method,
  so plugins should manually register extensions to it. To prepare for
  possible unbound compiler from Project API in future new  `K2ComponentRegistrar`
  introduced which provides registration method without Project at all
2022-06-29 11:59:58 +00:00
Dmitriy Novozhilov 7fa459044f [Test] Fix extracting path to standard libraries from incorrect places for external users 2022-06-29 06:41:07 +00:00
Dmitry Gridin 6e75e4a56e Revert "Revert "[light classes] drop old light classes and backend: iteration #12""
This reverts commit 732a08f0df.
2022-06-28 17:57:35 +02:00
Dmitry Gridin d14a71acfc Revert "Revert "[light classes] drop old light classes and backend: iteration #11""
This reverts commit 357e15085e.
2022-06-28 17:57:34 +02:00
Dmitry Gridin 28aa47af8a Revert "Revert "[light classes] drop old light classes and backend: iteration #10""
This reverts commit 4b3e48dc47.
2022-06-28 17:57:34 +02:00
Dmitry Gridin cbf9b13ef8 Revert "Revert "[light classes] drop old light classes and backend: iteration #9""
This reverts commit 38c623bc3a.
2022-06-28 17:57:33 +02:00
Dmitry Gridin 9f3a269d62 Revert "Revert "[light classes] drop old light classes and backend: iteration #8""
This reverts commit 91fa6af556.
2022-06-28 17:57:33 +02:00