Commit Graph

88666 Commits

Author SHA1 Message Date
Ilya Kirillov fceb46924e Move decompiler from IJ repository
This commit just moves files and fixes imports
2021-12-27 16:23:11 +03:00
Ilya Kirillov a367fee5cf Add newly added modules to the list of compiler modules 2021-12-27 16:23:11 +03:00
Ilya Kirillov 3779acbc3d Add testdata from intellij for cls stub building tests and generate tests 2021-12-27 16:23:11 +03:00
Ilya Kirillov 02d68d7b12 Introduce cls stub building tests (mostly migrated from intellij) 2021-12-27 16:23:10 +03:00
Ilya Kirillov 127dc7670e Move IDEKotlinBinaryClassCache from intellij 2021-12-27 16:23:10 +03:00
Ilya Kirillov b222bf88a0 Move DirectoryBasedClassFinder and DirectoryBasedDataFinder from intellij 2021-12-27 16:23:10 +03:00
Ilya Kirillov dbb3ebb8df Implement AnnotationLoaderForClassFileStubBuilder 2021-12-27 16:23:09 +03:00
Ilya Kirillov b9b0bb309d Move KotlinClsStubBuilder from intellij repository
This commit is just move, without any modifications
2021-12-27 16:23:09 +03:00
Ilya Kirillov 78db89b46b Extract AbstractBinaryClassAnnotationLoader to be used without FE1.0 2021-12-27 16:23:08 +03:00
Ilya Kirillov 52baf7338e Move KotlinBinaryClassCache to separate module, so it can be used outside FE1.0 2021-12-27 16:23:08 +03:00
Ilya Kirillov 25fe14b514 Move PerformanceCounter to runtime utils, so it can be used outside FE1.0 2021-12-27 16:23:07 +03:00
Ilya Kirillov 3686fc109d Extract AnnotationLoader from AnnotationAndConstantLoader, so it can be used without FE1.0 2021-12-27 16:23:07 +03:00
Ilya Kirillov 49e9c47071 Move DynamicTypeDeserializer.id from IR module to common module
So, it can be used from cls-psi-stub-builder module
2021-12-27 16:23:06 +03:00
Ilya Kirillov 53346e0aa6 Merge KotlinFileStubImpl and KotlinFileStubForIde into KotlinFileStubImpl
as the only difference is additional fields in KotlinFileStubForIde
2021-12-27 16:23:05 +03:00
Ilya Kirillov a9d7e5db72 Move stub builder stuff from intellij
This is mechanical moving without fixing compilation errors,
just packages are changes
2021-12-27 16:21:51 +03:00
Igor Chevdar af09fb51ac [K/N][IR] Made the compiler pipeline to do per file lowerings 2021-12-27 14:28:29 +05:00
Igor Chevdar d3a7aefe36 [K/N][IR] Turned off SAM super types checker
Fixes https://youtrack.jetbrains.com/issue/KT-50399
2021-12-27 08:42:30 +00:00
Hung Nguyen 78f10d9142 KT-45777: Keep only package facades whose members are looked up
to reduce the size of the shrunk classpath snapshot further.
2021-12-25 00:20:31 +03:00
Alexander Shabalin a6b5339980 [K/N] Fix a race in ThreadWithContextTest
Merge-request: KT-MR-5349
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com>
2021-12-24 18:49:26 +00:00
Roman Golyshev 3f8fff55cf FIR IDE: Fix ImportOptimizer for types used as generics' parameters 2021-12-24 16:31:34 +00:00
Pavel Punegov 4e402e1b72 [Native] Samples: update kotlin version and gradle 2021-12-24 16:03:40 +00:00
Hung Nguyen 9b96dbe2d2 KT-45777: Parse classes only once with ASM
to get both constants and inline functions.

Also add BasicClassInfo to ClassFileWithContents to simplify the code.
2021-12-24 18:31:49 +03:00
Hung Nguyen 9a995af0df KT-44741: Improve handling of constants defined in companion objects 2021-12-24 18:31:49 +03:00
Hung Nguyen a900f2b66d KT-45777: Reorganize unit test data for classpath snapshot feature
to make it easier to add more tests in the next commits.

- Add unit tests for constants and inline functions

Also add tests for different kinds of Kotlin classes: CLASS,
FILE_FACADE, MULTIFILE_CLASS.

-Add unit test for nested classes

Also remove the existing integration test for nested classes to keep the
integration tests focused on the key scenarios while unit tests will
cover the corner cases.

Ignore inline functions that are private
2021-12-24 18:31:49 +03:00
Iaroslav Postovalov 534cf0c6c8 stdlib: Simplify JS charArrayOf implementation (#4354)
#KT-16974 Fixed
2021-12-24 17:20:06 +03:00
Roman Artemev 93e7eb2a8e [JS IR] Cleanup StageController & Lowerings magic a bit 2021-12-24 16:50:47 +03:00
Roman Artemev 7341a17a5d [IR] Cleanup ir serialization 2021-12-24 16:50:44 +03:00
Roman Artemev 4babc30624 [IR] Remove Persistent IR 2021-12-24 16:50:42 +03:00
Roman Artemev 353bfe9018 [JS IR] Cleanup pir IC code 2021-12-24 16:50:40 +03:00
Roman Golyshev 287c23269a FIR IDE: Make getContainingPsi work with ItLambdaParameter source
It prevented the code completion to work in positions like
`"hello".let { <caret> }`
2021-12-24 16:19:30 +03:00
Sergey Bogolepov 1dd76fa637 [K/N] Re-enable Hypervisor framework
^KT-50045
2021-12-24 12:44:36 +00:00
Sergey Bogolepov 2f6b367e25 [K/N] Enable Kernel framework
Export only minimal set of headers that is required for Hypervisor.
2021-12-24 12:44:36 +00:00
Yahor Berdnikau 8bdb19a11e Deprecate 'kotlin.coroutines' property and extension
Deprecation 'kotlin.coroutines' property and related
'kotlin.experimental.coroutines' extension DSL. These properties
are not doing anything since 1.5.0 release and has to be removed long
time ago.

^KT-50369 Fixed
2021-12-24 11:55:56 +00:00
Alexander Shabalin 5de0f78350 [K/N] Extract SingleThreadExecutor.
^KT-48537

Merge-request: KT-MR-5338
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com>
2021-12-24 11:04:45 +00:00
Victor Petukhov d3ee284461 [FE 1.0] Check for readiness to fix for all type variables after try analysing a lambda with the builder inference
^KT-50498 Fixed
2021-12-24 13:37:45 +03:00
Ilya Muradyan bb34a74abb REPL: Fix completion for protected members 2021-12-24 08:34:40 +03:00
Evgeniy.Zhelenskiy 610429a278 [Tests] Move non-value class test to the corresponding folder 2021-12-24 00:26:18 +00:00
Stanislav Erokhin 61526c9700 Move AbstractJsScriptlikeCodeAnalyser to the kotlin-scripting-compiler-js module 2021-12-23 20:10:19 +03:00
Ilya Goncharov 52ccf3d6ec [JS IR] Not export fun with stable name and default argument
if it is not exported, but just with stable name

^KT-50464 fixed

Merge-request: KT-MR-5324
Merged-by: Ilya Goncharov <Ilya.Goncharov@jetbrains.com>
2021-12-23 15:21:00 +00:00
Mikhail Glukhikh 61e0375900 Drop YIELD_IS_RESERVED diagnostic in 1.7.0 #KT-27750 Fixed 2021-12-23 17:45:50 +03:00
Mikhail Glukhikh 0739925869 Drop QUALIFIED_SUPERTYPE_EXTENDED_BY_OTHER_SUPERTYPE diagnostic in 1.7.0
#KT-49016 Fixed
2021-12-23 17:45:49 +03:00
Mikhail Glukhikh f53cd22253 FIR: copy builder inference session when creating snapshot for locals
This commit fixes one builder inference case from KT-49925
2021-12-23 17:28:01 +03:00
Mikhail Glukhikh 3f02309dad FIR: add example 2 from KT-49925 (fails yet) 2021-12-23 17:27:59 +03:00
Mikhail Glukhikh dde4c46df7 FIR: add original test from KT-49925 (passes) 2021-12-23 17:27:56 +03:00
Ilya Matveev 2f32214106 [K/N][Runtime] Fix deadlock in file initialization
Issue #KT-50491 Fixed
2021-12-23 13:21:01 +00:00
Pavel Kunyavskiy fd63fed8b4 [K/N] Filecheck test for EnumWhenLowering 2021-12-23 11:09:29 +00:00
Pavel Kunyavskiy 60cb8543f0 [K/N] Add test for tls load optimisation
^KT-50139
2021-12-23 11:09:28 +00:00
Pavel Kunyavskiy 1956fcb14f [K/N] Add test for inlining of adopted function reference
^KT-48179
2021-12-23 11:09:28 +00:00
Pavel Kunyavskiy c97f4a4d20 [K/N] Support -Xsave-llvm-ir-after compiler option 2021-12-23 11:09:27 +00:00
Victor Petukhov 0689d74353 [Compiler CLI] Use LanguageVersion.LATEST_STABLE instead of KotlinVersion.CURRENT for java type enhancement settings to prevent dependency on kotlin version. 2021-12-23 13:42:58 +03:00