Commit Graph

87350 Commits

Author SHA1 Message Date
Yan Zhulanow b8682f04f3 [FIR IDE] Treat enum entry members as local in AAPI/FE10
This commit partially fixes KtFe10SymbolByPsiTestGenerated.testEnumValueMember().
2021-11-12 20:09:49 +09:00
Yan Zhulanow 944ec7ba5a [FIR IDE] Don't return 'open' modality for final class members in AAPI/FE10
This commit partially fixes KtFe10SymbolByPsiTestGenerated.testEnumValueMember().
2021-11-12 20:09:49 +09:00
Yan Zhulanow 94ca387405 [FIR IDE] Fix callableIdIfNonLocal for accessors in AAPI/FE10
Before the behavior was rather random and erroneous. Now the callable id
is also 'null' for Kotlin property accessors, and accessor method id
for synthetic Java properties.
2021-11-12 20:09:49 +09:00
Yan Zhulanow 4f7dc1122f [FIR IDE] Fix KtSymbolProvider.getParameterSymbol() in AAPI/FE10
For loop parameters, Analysis API expects a local variable to be
returned. The additional check regarding lambda parameters is also added
to reflect the FIR behavior.

This commit partially fixes KtFe10SymbolByPsiTestGenerated.testForLoopVariable().
2021-11-12 20:09:49 +09:00
Yan Zhulanow 7934b263c1 [FIR IDE] Fix KtSymbolInfoProvider.getJavaSetterName() in AAPI/FE10
Before the change, the getter name was erroneously returned instead
for properties without a @JvmName() annotation.

This commit fixes KtFe10SymbolByPsiTestGenerated.testBackingField().
2021-11-12 20:09:49 +09:00
Yan Zhulanow d5e26bcf9e [FIR IDE] Refactoring, introduce Fe10AnalysisContext.builtIns 2021-11-12 20:09:48 +09:00
Yan Zhulanow a0e28972d5 [FIR IDE] Always provide accessors from property symbols in AAPI/FE10 2021-11-12 20:09:48 +09:00
Yan Zhulanow 0099e6e81b [FIR IDE] Unify origin logic in AAPI/FE10 2021-11-12 20:09:48 +09:00
Yan Zhulanow e943ee1e33 [FIR IDE] Fix callableIdIfNonLocal in AAPI/FE10
Before, implementations of 'callableIdIfNonLocal' in Fe10KtSymbols
returned CallableIds even for local declarations. This commit fixes this
behavior.

This commit fixes KtFe10SymbolByPsiTestGenerated.testLocalDeclarations().
2021-11-12 20:09:48 +09:00
Yan Zhulanow f7b4fa64ea [FIR IDE] Fix Fe10PsiKtEnumEntrySymbol.annotatedType in AAPI/FE10
'annotatedType' should return type of the enum itself, not of its entry.
This commit fixes KtFe10SymbolByPsiTestGenerated.testEnum().
2021-11-12 20:09:48 +09:00
Yan Zhulanow 47b5474955 [FIR IDE] Decouple KtFe10AnalysisSession and symbols 2021-11-12 20:09:47 +09:00
Yan Zhulanow b075fe8741 [FIR IDE] Fix CliFe10AnalysisFacade, so it can be used as a Project component 2021-11-12 20:09:47 +09:00
Yan Zhulanow 0388f1e5ca [FIR IDE] Refactoring, accept only KtElement sources in KtFe10AnalysisSession 2021-11-12 20:09:47 +09:00
Yan Zhulanow 0382323dad [FIR IDE] Refactoring, make KtFe10AnalysisSession final 2021-11-12 20:09:47 +09:00
Yan Zhulanow b59067ca45 [FIR IDE] Extract CLI parts of KtSymbol-aware KtReferences 2021-11-12 20:09:46 +09:00
Mikhail Glukhikh d6bc6bec59 FIR2IR: read extension function type attribute properly 2021-11-12 12:53:32 +03:00
Mikhail Glukhikh b2d020606e FIR: don't generate extension callable reference without receiver 2021-11-12 12:53:29 +03:00
Mikhail Glukhikh bcfd970ac5 FIR2IR: add comments about translation phases 2021-11-12 12:53:25 +03:00
Mikhail Glukhikh d91384434c Drop some unnecessary casts in FIR code 2021-11-12 12:53:22 +03:00
Mikhail Glukhikh 3263d4d003 FIR2IR: split local class on-the-fly creation into two phases 2021-11-12 12:53:19 +03:00
Jinseong Jeon 4a16027873 FIR IDE: find source of deserialized top-level properties 2021-11-12 12:11:06 +03:00
Jinseong Jeon cf886c5975 FIR LL: fix searching logic for enum entry
KtEnumEntry, a subtype of KtClass, has been handled by
findNonLocalClass. Since KtEnumEntry doesn't have class id, that util
always throws an error while retrieving class id.

Instead, we should use containing class (i.e., enum class) id.
Also, once the enum class is resolved, we should search for matching
enum entry inside the enum class.
2021-11-12 12:11:06 +03:00
Jinseong Jeon 140b8d6ddf FIR LL: remove redundant test data for library module resolve
There are in plugins/kotlin/fir-low-level-api-ide-impl in intellij repo.
2021-11-12 12:11:05 +03:00
Ilya Matveev 428a15397e [K/N] Suppress warnings of dsymutil in runtime tests 2021-11-12 05:42:00 +03:00
Ilya Matveev 54cdf732b4 [K/N] Enable debug info for runtime tests 2021-11-12 05:42:00 +03:00
Ilya Goncharov d6112224b4 [JS IR] Generate references from fake override to body in case of generic superclass 2021-11-11 15:12:34 +00:00
Pavel Punegov 475b3a452e [K/N][test] Disable tests on wasm due to ^KT-48738 2021-11-11 13:34:25 +00:00
Pavel Punegov 83d31526cc [K/N][build] Fix args in klib runner task 2021-11-11 12:16:27 +00:00
Pavel Punegov 2bb5a554a8 [K/N][build] Small fix to platformLibs build script 2021-11-11 12:16:27 +00:00
Pavel Punegov 197d55e045 [K/N][build] Add common sources setting to Konan plugin
Used for stdlib build
2021-11-11 12:16:26 +00:00
Pavel Punegov e07fa31784 [K/N][build] Move KLibInstall to Konan gradle plugin 2021-11-11 12:16:26 +00:00
Pavel Punegov 151cb096ce [K/N][test] Replace genKt39548 task with doBeforeBuild closure 2021-11-11 12:16:25 +00:00
Pavel Punegov 547501865c [K/N][build] PlatformLibs project small refactorings 2021-11-11 12:16:25 +00:00
Pavel Punegov 04c6e64598 [K/N][build] KLibInstall task fix removing useless doFirst 2021-11-11 12:16:24 +00:00
Pavel Punegov 0c47ac3cd0 [K/N][build] Rewrite platforms libs to kts 2021-11-11 12:16:24 +00:00
Pavel Punegov 3abc587125 [K/N][build] KlibInstall minor fixes 2021-11-11 12:16:23 +00:00
Pavel Punegov c1ad88f1a6 [K/N][build] Move stdlib bitcode copy to runtime 2021-11-11 12:16:23 +00:00
Pavel Punegov eb5518d6d7 [K/N][build] Fixes to caching and stdlib build 2021-11-11 12:16:22 +00:00
Pavel Punegov 67eedbe03e [K/N][build] Move stdlib caching to runtime project 2021-11-11 12:16:22 +00:00
Pavel Punegov c9d203b01a [K/N][build] stdlib cross-target build
Build stdlib only for host platform and copy to cross-targets just
changing the manifest
2021-11-11 12:16:21 +00:00
Pavel Punegov e9b1f7cca1 [K/N][build] Move stdlib build to runtime project
Build stdlib with konan plugin in runtime project
2021-11-11 12:16:21 +00:00
Ilya Goncharov c30292a472 [Gradle, JS] Close zip file after reading 2021-11-11 10:25:53 +00:00
Ilya Goncharov 4efde83772 [Gradle, JS] New rules for zipped klib in zip 2021-11-11 10:25:53 +00:00
Ilya Goncharov 3ef5e36425 [Gradle, JS] Use formal check of klibs in gradle plugin 2021-11-11 10:25:53 +00:00
Yahor Berdnikau 18ff64a28f Move jvm toolchain tests under jvm platform test tag.
^KT-45745 In Progress
2021-11-11 10:46:35 +01:00
Dmitriy Dolovov 1e8dbd4846 [Native][tests] Add ExperimentalContracts OPT_IN directive for kt47300.kt
Without this directive the test can't be compiled by Kotlin/Native, because the box() function which is annotated with @ExperimentalContracts is called from the generated test runner source code that itself is not marked by this annotation.
2021-11-11 12:33:00 +03:00
Dmitriy Dolovov e7caaa464e [Test] Fix using classes as annotation parameters in generated classes 2021-11-11 12:32:53 +03:00
Dmitriy Dolovov f3397dfeca [Native][tests] Fix "outputChecker cannot be serialized" Gradle issue 2021-11-11 12:32:47 +03:00
Ilya Muradyan 57543f5b19 [scripting] Fix NPE in aether.kt 2021-11-11 11:27:07 +03:00
Alexander Udalov 27cfcb9b3d IR: fix thisReceiver parameter type for function classes
Incorrect builder was used at line 269, which led to non-sensible type
in `IrClass.thisReceiver` for function types, such as
`SuspendFunction1<SuspendFunction1, SuspendFunction1>` in the linked
issue.

Avoid creating types manually completely to simplify this code and fix
the bug.

 #KT-49168 Fixed
2021-11-10 21:58:41 +01:00