Calling createIrEnumEntry lead to "IllegalStateException:
Fir2IrEnumEntrySymbol for [declaration] is already bound" when the
IrEnumEntry was already created previously, e.g. by an annotation call
referencing it.
^KT-54079 Fixed
Root cause:
Cached in ClassValue values are prohibited to reference any java.lang.Class or ClassValue instances as they are considered as strong roots that prevent Class and ClassValue garbage collection,
creating effectively unloadable cycle.
This problem is also known as JDK-8136353.
Actions taken:
* Extract anonymous ClassValue instance into a separate static class that does not capture anything implicitly
* Wrap cached values in ClassValue into SoftReference to avoid unloadable cycles
^KT-56093 Fixed
Calling '.addAll()' was replacing convention value leading for inability
to add/modify Kotlin/Native link task freeCompilerArgs via
KotlinCompilation.options.freeCompilerArgs. For now convention
was replaced by normal value.
^KT-56280 Fixed
and assert that symbol is not a substitution/intersection override
in the `compute` method otherwise.
Because `fakeOverrideSubstitution` should be calculated for all real
implicit types, no call to this method should actually happen.
Otherwise, it can be problematic to create a session
which would contain the full designation path:
`provider.getFirCallableContainerFile(symbol)`
returns `firFile` of a super class which might be from module `a`,
when declaration and its outer classes are from module `b`.
^KTIJ-24105
This fixes test failures when advancing bootstrap.
When a language feature has UNSTABLE_FEATURE kind, enabling it causes
the compiler to mark the compiled library with the pre-release flag.
JsAllowImplementingFunctionInterface feature is enabled by default in
Wasm backend. So effectively, all Wasm klibs are marked with the
pre-release flag, including the standard library.
Pre-release checks were enabled recently and cause compiler errors.
To fix the problem, this commit changes the feature kind to OTHER, which
doesn't enforce the pre-release flag.
Merge-request: KT-MR-8582
Merged-by: Svyatoslav Kuzmich <svyatoslav.kuzmich@jetbrains.com>
Add debug information for inline function parameters
Previously during debugging Kotlin/Native applications you couldn't inspect the inline function or inline lambda parameters. This happened because the debug information for them wasn't generated at all. To fix this issue we have to store the information about which expressions were inlined instead of which parameters. This commit adds a new mapping, which allows storing the required information during the inlining phase. The mapping is then reused during the bitcode generation phase to add the debug information for inline function parameters.
^KT-55440
Resolver could be GCed if there is no any valid hard reference to it.
Some impl of PackageFragmentProvider (like DelegatingPackageFragmentProvider)
keep hard ref to resolver.
For the sake of investigation it is worth to know what kind of PFP is there.
#EA-725255
Merge-request: KT-MR-8581
Merged-by: Vladimir Dolzhenko <Vladimir.Dolzhenko@jetbrains.com>
depends on closure of its default source set.
With HMPP it is no longer needed, since each source compiles
independently and sees its parent declarations via klib dependencies
^KT-55730 Verification Pending
The original synthetic properties from Java were not cached anywhere and
created anew for every session. However, the enhanced properties are
(along with their originals) saved inside the session's cache, causing
inconsistency with newly created symbols via referential equality.
- The fix for KT-55570 caused some backend tests to fail, because errors
are now correctly reported for simple classes and actual/expect in
the same module is not supported in FIR. See KT-55177.
- The commit also adds separate tests for K2. Unfortunately, these have
to be disabled for K1 because K1 then reports "expect without actual"
errors.
- In contrast to other kinds of dependencies, `dependsOn` dependencies
must be followed transitively.
- Add `transitiveDependsOnDependencies` to `KtModule`. These
dependencies are calculated lazily with a topological sort. They are
added to the dependency provider when it's built in
`LLFirSessionFactory`.
^KT-55329 fixed
- `IncDecOperatorsInExpectClass.kt` should produce an
`ACTUAL_WITHOUT_EXPECT` in K2 (see KT-55177). This went unnoticed
because of KT-55570.
- A similar multi-module test for K1 and K2 has been added, called:
`multiplatform/incDecOperatorsInExpectClass.kt`.
- FirExpectActualMatcherTransformer: Instead of returning,
`transformMemberDeclaration` must assign an empty map to
`expectForActualData` so that `FirExpectActualDeclarationChecker`
doesn't assume that the member declaration needs no expect-actual
checking.
^KT-55570 fixed