Commit Graph

95219 Commits

Author SHA1 Message Date
Steven Schäfer 760f89efd3 FIR: Fix operator and infix flags for FIR builtins 2022-10-05 12:14:05 +00:00
Ilmir Usmanov 808a73d5b9 FE: Change misleading error message 2022-10-05 11:51:20 +00:00
Marina.Shishkina 53219d60e6 Add changelog for 1.7.20 2022-10-05 13:29:12 +02:00
Margarita Bobova 3424614752 Add changelog for 1.7.10 2022-10-05 13:29:11 +02:00
Nikolay Krasko b5b58f40d6 Workaround instability of Gradle builds caused by the default encoding
The encoding setting from org.gradle.jvmargs is not applied
(https://github.com/gradle/gradle/issues/22292) during
the :kotlin-stdlib-js:compileJs, causing instability in kotlin.js.map
(https://youtrack.jetbrains.com/issue/KT-50589) on machines where
default encoding is not UTF-8.

This reverts commit d7ef5efa6a.

KTI-932
2022-10-05 10:57:46 +00:00
Sergey Bogolepov 289f540530 [Commonizer] workaround for CoreGraphics from Xcode 14 2022-10-05 09:59:10 +00:00
Sergey Bogolepov 94c705d608 [K/N] Remove LocalEscapeAnalysis
It was disabled for a long time because we have
a proper one now.
2022-10-05 08:31:32 +00:00
Sergey Bogolepov 2efcc21d21 [K/N] Extract KonanConfig-dependent methods from Context
Introduce ConfigChecks interface which can be reused between different
classes.
2022-10-05 08:31:32 +00:00
Sergey Bogolepov 60ee30a28d [K/N] Remove some unused code from Context 2022-10-05 08:31:32 +00:00
Sergey Bogolepov 2437e8a06c [K/N] Extract descriptors search from Context into a DescriptorsLookup
Reduces dependency on Context class in Kotlin/Native backend.
2022-10-05 08:31:31 +00:00
Pavel Kunyavskiy 467d2b42fc [K/N] Make AbstractSuspendFunctionsLowering independent of files order
When coroutine class is created, it's made child of SuspendFunction
class. Normally, SuspendFunction class can't be already lowered,
but if we are compiling stdlib it can happen. And if it is
bad fake overrides would be created before this commit.

Unfortunately, as problem can happen only during stdlib compilation,
no specific test can be added.
2022-10-05 06:27:39 +00:00
pyos 5ba76ee757 FIR: convert Java type parameter bounds before reading annotations
This avoids a crash due to circular class references through annotation
arguments.
2022-10-04 19:48:15 +00:00
Dmitriy Novozhilov 04dae17333 [Assign plugin] Add assign plugin to the list of plugins for compiler dist 2022-10-04 19:47:34 +00:00
Dmitriy Novozhilov c543a2e6d5 [Assign plugin] Publish embeddable version of assign plugin 2022-10-04 19:47:34 +00:00
Pavel Kunyavskiy 0959255379 [K/N] Refactor GC logging and statistics
Same code is now used for GC logging in all gc versions.

^KT-53064
2022-10-04 18:44:58 +00:00
Pavel Kunyavskiy c4e2901a1d [K/N] Avoid inlining of ignored check on external call 2022-10-04 18:44:58 +00:00
Sergey Bogolepov 6ff282eca3 [K/N] Remove contents of NEW_MM.md 2022-10-04 16:26:45 +00:00
Sergey Bogolepov e669ad95fa [K/N] Compare distributions as a whole
We might move declarations between platform libraries
preserving their fqname. To make diff simpler
let's collect signatures from all platform libraries
and compare them together instead of per-file basis.
2022-10-04 18:27:45 +03:00
Ilya Kirillov 49f2f85927 [Low Level FIR] fix exception when creating symbol by invalid code 2022-10-04 12:56:07 +00:00
Ilya Kirillov 24bf273b93 [Low Level FIR] add more info to error in LLFirResolvableResolveSession 2022-10-04 12:56:06 +00:00
Nikolay Lunyak e2fdb352f1 [FIR] KT-42962: Ensure the issue is not present in K2
Merge-request: KT-MR-7288
Merged-by: Nikolay Lunyak <nikolay.lunyak@jetbrains.com>
2022-10-04 12:27:17 +00:00
Alexander Shabalin 049b6899b7 [K/N] Fix RTTIGenerator.kt ^KT-54163
Merge-request: KT-MR-7289
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com>
2022-10-04 10:42:20 +00:00
Sergej Jaskiewicz c9c50ff73c [JS IR] Disable some flaky stepping tests
^KT-54283
2022-10-04 10:31:14 +00:00
Sergey Bogolepov 860f873ac7 [K/N] DI some properties of ObjCExport
Move `exportedInterface` and `codeSpec` to constructor's
parameters, so in the future "dynamic" compiler pipeline
they can be created independently.
2022-10-04 10:03:11 +00:00
Alexander Shabalin 98251f42f2 [K/N] Specialize marking call for objects ^KT-54163
Merge-request: KT-MR-7232
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com>
2022-10-04 09:51:08 +00:00
Aleksei.Cherepanov 377082ee43 Update cache version due to change of logic in PathStringDescriptor
Update cache version after critical change: be71d884 Use case-sensitive logic in PathStringDescriptor for all platforms

#KT-53932 Fixed
2022-10-04 09:13:19 +00:00
Artem Kobzar 574d774277 [K/JS] Remove illegal chars from the new js-minimal-stdlib path 2022-10-03 15:59:07 +00:00
Ilya Kirillov 81c52e6886 [Analysis API FIR] fix call resolution on error elements 2022-10-03 16:02:23 +02:00
Ilya Kirillov 2d7218b542 [Analysis API FIR] fix test generation 2022-10-03 16:02:23 +02:00
Ilya Kirillov ab3f916f3f [Analysis API FIR] fix call resolution of non-resolvable elements 2022-10-03 16:02:23 +02:00
Leonid Startsev ccdb6fc599 Fix .equals for instantiated annotations with unsigned array types.
#KT-53876 Fixed
2022-10-03 13:54:06 +00:00
Simon Ogorodnik 0fea8073ef Scripting Plugin. Update CoreFileTypeRegistry under lock
CoreFileTypeRegistry isn't thread-safe, so it should be updated under
application lock, to avoid concurrently mutating underlying structure
2022-10-03 13:36:06 +00:00
Simon Ogorodnik 53069ee03f Fix application disposer registered only once due to deduplication
Disposer uses passed object identity to decide should it be registered
Since lambda, that passed into disposer doesn't capture anything, it has
only one instance, so it ends up being registered only once
While it should be registered for every parentDisposable
2022-10-03 13:36:05 +00:00
Simon Ogorodnik f2dee2bf85 Core. Fix data-race in ApplicationEnvironment initialization
getOrCreateApplicationEnvironment is main entrypoint to create
ApplicationEnvironment in production and compiler tests
It is subject to be called concurrently, that's why
APPLICATION_LOCK exists

ApplicationEnvironment itself hosts Application from idea-core
It is actually singleton, that is subject to be disposed, once all
operations referencing it completes

To properly dispose ApplicationEnvironment when there is no references
left, we maintain reference counter aka ourProjectCount

Originally, there was data-race caused by the fact, that ourProjectCount
was updated after publication of application

Linear, data-race occurs in following order
T1: getOrCreateApplicationEnvironment returns application
T2: Disposes its reference to application, causing ourProjectCount to
reach zero, and disposing application that is already available to T1
T1: Updates counter, but its application already disposed
2022-10-03 13:36:05 +00:00
Dmitriy Novozhilov a6c7d4c0c6 [FIR] Analyze bodies of non delegated property accessors without expected type
^KT-53349 Fixed
2022-10-03 15:48:17 +03:00
Dmitriy Novozhilov c5fd248e69 [FIR] Add pretty toString to ResolutionMode 2022-10-03 15:48:17 +03:00
Dmitriy Novozhilov 6623456d2a [FIR] Properly support @JvmRecord
^KT-53867 Fixed
2022-10-03 15:48:17 +03:00
Dmitriy Novozhilov c0ad67c4f9 [FIR] Generate java declarations for record components of java records
^KT-53964 Fixed
2022-10-03 15:48:17 +03:00
Sergey Bogolepov 2ed6e9febf Revert "[K/N] DI some properties of ObjCExport"
This reverts commit 4d15aa11c2.
2022-10-03 15:22:36 +03:00
Sergey Bogolepov 4d15aa11c2 [K/N] DI some properties of ObjCExport
Move `exportedInterface` and `codeSpec` to constructor's
parameters, so in the future "dynamic" compiler pipeline
they can be created independently.
2022-10-03 15:21:44 +03:00
Nikolay Krasko 20692c9837 Minor: cleanup code in cli-js and js.sourcemap 2022-10-03 11:08:29 +00:00
Artem Kobzar eb2326eabb [K/JS] Add ability to exclude declarations from export by a new annotation @JsExport.Ignore. 2022-10-03 11:07:25 +00:00
Abduqodiri Qurbonzoda 917c8606f5 Document @Synchronized behavior on extension functions #KT-32469 2022-10-03 10:16:37 +00:00
Ilya Kirillov dd9ed02fbd [FIR] fix memory leak via static ConeIntegerLiteralTypeImpl.COMPARABLE_TAG 2022-10-02 20:38:34 +00:00
Ilya Gorbunov 607f15b55b Sycnhronize docs of primitives in JS-IR, Wasm, Native sources 2022-10-02 19:04:37 +00:00
Ilya Gorbunov 34de2d9155 Trim trailing spaces in generated docs of builtins 2022-10-02 19:04:36 +00:00
Ilya Kirillov 9ac9bef20f [FIR] fix nested access to FirCache
it's forbidden by the contract and causes ISE "Recursive update" or deadlock in the IDE
2022-10-02 19:00:02 +02:00
Ilya Kirillov e5a941030b [Low Level FIR] fix CME in java enhancement
Now all computations in FirThreadSafeCache are performed under lock

^KTIJ-23081 fixed
2022-10-02 19:00:02 +02:00
Jinseong Jeon fc1eb02590 SLC: implement PsiVariable#computeConstantValue for light field 2022-10-02 13:41:12 +02:00
Jinseong Jeon a58e0803fb ULC: output update (annotation on enum entry)
Input has `// CHECK_BY_JAVA_FILE`
and thus ULC output as .java file should be updated too
when input was changed to add annotation on enum entry
(at commit c5916e1d)
Tested by UltraLightClassLoadingTestGenerated in IntelliJ
2022-10-02 13:41:12 +02:00