Correctly handle `KtDotQualifedExpression`s with function calls as
selectors (like `foo.Bar()`). Without such handling, processing of
member invoke calls on objects was broken both
for reference shortener (causing KTIJ-26695)
and import optimizer (causing KTIJ-23407)
Also, to fix KTIJ-23407, do not ignore qualifiers with
`ImplicitInvokeCall` fake source
^KTIJ-26695 Fixed
^KTIJ-23407 Fixed
To check that boolean "is" prefix is treated correctly, and Unit return
type is not translated to void. `@Deprecated` annotations are added just
so that the `$annotations` methods would also be generated.
In normal circumstances, it leads to the field `c$delegate` NOT being
generated (see KT-39054). However, it's not the case in kapt in any
mode:
- In the old JVM backend, this optimization is not supported.
- In JVM IR, property initializers are missing in light analysis, so
backend cannot figure out that this property is optimizable.
- In kapt4, backend is not being run, and symbol light classes do not
have information about this optimization.
Overall it doesn't matter much which stub is generated here because the
field is private, the test is added just in case.
Also adds rendering of @Metadata annotations in Kapt3 and Kapt4 tests
(currently disabled for a few tests).
Co-authored-by: Alexander Udalov <alexander.udalov@jetbrains.com>
`resolvePhase` from `FirFile` is not an indicator of resolution state for
the entire file, so we shouldn't depend on it.
The right check will be performed during `lazyResolveTargets` over `LLFirResolveTarget`
^KTIJ-26666 Fixed
^KT-61296
This information is needed to create consumable configurations for
Commonized Cinterop outputs. This way CInteropCommonizerTask is not
required to be created eagerly.
^KT-59596 Verification Pending
Introduce *CommonizedCInterop & *CommonizedCInteropElements configurations
and fix CInteropCommonizerTask to consume dependencies / expose artifacts
via these configurations.
Previously, `retryOnInvalidSession` was needed to try resolving declaration again if the `FirSession` is invalidated and PCE was thrown.
Currently, we do not invalidate `FirSession` on PCE as we can restore the FIR tree state after the PCE was thrown.
Now `FirSession` might be invalidated only on OOBM or module content root modification, in this case, we should not get access to the invalidated `FirSession` at all
It's possible to write a fix that
would prevent false positives with
this checker, but the core
intuition behind it is invalid.
This checker assumes that it's
enough to only check direct
overriddens, while in reality
even simple `Source` override
functions are not allowed to
contain default values, so they
can't be used to make judgements
about them.
^KT-59408 Open
^KT-59408 Open
^KT-61095 Fixed
^KT-61165 Fixed
^KT-61029 Fixed
The fixed error leaded to the invalid resolve of methods during
evaluation, e.g. kotlinx.coroutines#runBlocking should be called from
facade BuildersKt instead of BuildersKt__BuildersKt
IrSetField was transformed to its value to preserve side effects
This transformation produced invalid IR in cases where
IrSetField used in Unit-returning expression context.
This commit fixes it by producing Unit-typed expression
^KT-59084 Fixed
This fixes a KMP issue where IrActualizer would add duplicate
fake overrides because the parent class would have both the getter
and the synthetic property in its list of declarations.
Now, the synthetic property fake overrides are still generated and
cached in the Fir2IrDeclarationStorage, but not added to the class.
#KT-60854 Fixed
The test data is used both in ":kotlin-util-klib-abi" and
":native:native.tests" modules. It's better to keep it together with
the test data for other KLIB tests which are also used in more than one
module, i.e. in "compiler/testData/klib/" dir.