Commit Graph

93482 Commits

Author SHA1 Message Date
Nikita Nazarov 38d97d0621 Add a key to enable spilling of all variables in a suspending context
This commit adds a new key that will allow users to enhance their
debugging experience in suspending contexts when using the IR backend.
After the key is enabled, the following things are changed:
1. All variables in a suspending context are spilled regardless their
liveness.
2. Their LVT records are not shrunk.
3. ACONST_NULL is not spilled to dead variables.

#KT-48678 In progress
2022-07-02 18:29:18 +03:00
Nikolay Krasko 2bdd45f659 Update space images
Follow the https://helpserver.labs.jb.gg/help/space/internal/set-up-a-dev-evnvironment.html#warm-up-dev-environment guide
2022-07-02 00:39:51 +02:00
Ilya Kirillov 445c0deb61 [Analysis] fix race in registering services in test 2022-07-01 21:08:18 +02:00
Ilya Kirillov 21fcb9ccc0 [Analysis API] add checks that KtLifetimeOwners are not leaked to other analyse scope 2022-07-01 21:08:18 +02:00
Ilya Kirillov aca8643262 [Symbol LC] rename analyseForLightClasses -> analyzeForLightClasses 2022-07-01 21:08:18 +02:00
Ilya Kirillov 00b893444c [Analysis API] remove unneeded analyzeWithSymbolAsContext 2022-07-01 21:08:18 +02:00
Ilya Kirillov 3dffe828b1 [Symbol LC] get rid of usage of analyzeWithSymbolAsContext for LC 2022-07-01 21:08:18 +02:00
Nikolay Krasko 397ddb7d2c Add isCacheRedirectorEnabled to kotlin common build properties 2022-07-01 18:44:48 +00:00
Nikolay Krasko 5b8a4ccd56 Use cache-redirector for downloading in parcelize tests
There's a flaky failures when
~/.m2/repository/org/robolectric/android-all/5.0.2_r3-robolectric-r0/android-all-5.0.2_r3-robolectric-r0.jar
is partially downloaded during tests execution.
This led to Parcelize tests failure with:

Caused by: java.util.zip.ZipException: invalid LOC header (bad signature)
 at java.util.zip.ZipFile.read(Native Method)
 at java.util.zip.ZipFile.access$1400(ZipFile.java:60)
 at java.util.zip.ZipFile$ZipFileInputStream.read(ZipFile.java:734)
 at java.util.zip.ZipFile$ZipFileInflaterInputStream.fill(ZipFile.java:434)
 at java.util.zip.InflaterInputStream.read(InflaterInputStream.java:158)
 at java.io.FilterInputStream.read(FilterInputStream.java:133)
 at java.io.FilterInputStream.read(FilterInputStream.java:107)
 at org.robolectric.util.Util.copy(Util.java:21)
 at org.robolectric.util.Util.readBytes(Util.java:38)
 at org.robolectric.internal.bytecode.SandboxClassLoader.getByteCode(SandboxClassLoader.java:166)
... 36 more

Option used was found at https://github.com/robolectric/robolectric/blob/7697d1217c5eb0dee454004efe60ba219f398255/plugins/maven-dependency-resolver/src/main/java/org/robolectric/MavenRoboSettings.java#L19

^KTI-842 Fixed
2022-07-01 18:44:48 +00:00
Ilya Gorbunov 3a029b8e80 Fix ValueTimeMark adjustment in rare cases and properly test it 2022-07-01 15:20:22 +00:00
Mikhail Glukhikh 4737bb07df FIR: look for conflicting declarations more precisely 2022-07-01 15:07:48 +00:00
Mikhail Glukhikh 3092a84b6b Drop unreachable when branch in FirConflictsChecker 2022-07-01 15:07:48 +00:00
Nikolay Krasko c7fc4cdfdf Update environment containers
Move to same project to avoid problems with tha authorizations
2022-07-01 13:40:24 +00:00
Nikolay Krasko 48a2ef040e Fix publication for kotlin-gradle-plugin-idea-proto
Javadoc and sources were missing.
2022-07-01 13:40:24 +00:00
Nikolay Krasko c67c615fa3 Allow to disable progressive mode with the false value 2022-07-01 13:40:23 +00:00
Ilya Gorbunov 0546b0902c Fix line endings ruined after applying line filter
Line filtering causes output file have platform-specific line endings.
Apply another filter to fix them to LFs.
2022-07-01 13:16:11 +00:00
Ilya Gorbunov f422845b9c Test open FP ranges with NaN bound
#KT-52932
2022-07-01 13:11:42 +00:00
Ilya Gorbunov 73084e5a68 Add tests for endExclusive property
Now, after a bootstrap, it's possible to use it

#KT-52932
2022-07-01 13:11:42 +00:00
Ilya Gorbunov d825af7a22 Switch language version in Kotlin project to 1.8
Use kotlinx-metadata-jvm:0.5.0 that supports reading 1.8.0 kotlin metadata version
2022-07-01 13:04:03 +00:00
Ilya Chernikov 854127bcc8 Fix testdata after switching Kotlin to version 1.8
(see the previous commit with the same title for details)
2022-07-01 14:31:45 +02:00
Ilya Chernikov 513f490502 Scripting: notify writer in REPL on errors reporting complete
required for restoring compatibility with IDE REPL usages (scratch
files included), since IDE counterpart needs a reliable signal
when the processing of the REPL snippet/command is completed
2022-07-01 10:14:42 +00:00
Ilya Kirillov 77758d1552 [Analysis] do not reregister services in AbstractStubBuilderTest 2022-07-01 11:33:21 +02:00
Ilya Kirillov 271ecfbd68 [Analysis] Try to fix randomly failing tests because of unregistered FileAttributeService
It should be unregistered with the application by ApplicationEnvironmentDisposer
which is registered in :compiler:tests-common-new
2022-07-01 11:33:21 +02:00
Bart van Helvert 7bef560b6b KTIJ-21986 Don't log non-kotlin code fragment context when it's null
This warning shouldn't be logged when the context is null.
2022-07-01 08:15:58 +00:00
Roman Golyshev 79ba790b38 [FIR IDE] Add support for new types of predicates for compiler plugins 2022-07-01 07:42:54 +00:00
Ilya Chernikov bc1e3667ff Fix testdata after switching Kotlin to version 1.8
the corresponding features - GenericInlineClassParameter && DataObjects
- were turned on in 1.8 right after the last check build, therefore the
discrepancy went unnoticed
2022-06-30 16:34:14 +00:00
Pavel Mikhailovskii 8a402bcacd KT-52875 Fix extension function literal creation with -Xlambdas=indy 2022-06-30 14:13:05 +00:00
Alexander Shabalin 97c542dd76 [K/N] Fix performance project
Merge-request: KT-MR-6567
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com>
2022-06-30 09:08:23 +00:00
Ilmir Usmanov a5084c2f69 JVM IR: Make receiver type of IrGetField not null
otherwise, it will be mapped to inline class type if underlying type
is primitive of nullable.

 #KT-52913 Fixed
2022-06-30 01:28:09 +00:00
Dmitriy Novozhilov cb1a8bd687 Advance bootstrap to 1.8.0-dev-6 2022-06-29 20:35:16 +03:00
Mikhail Glukhikh 2b235e1188 FE10 Analysis API: use compact renderer for flexible types even in debug 2022-06-29 16:50:06 +00:00
Mikhail Glukhikh 38f4a35be2 FIR: introduce flexible types pretty rendering for no arguments case
#KT-52020 Fixed
2022-06-29 16:50:05 +00:00
Mikhail Glukhikh 31ec10142b FirRenderer: add renderAllModifiers and renderDetailedTypeReferences
Related to KT-52020
2022-06-29 16:50:04 +00:00
Mikhail Glukhikh b2a9ad079d Fix unreachable branch in ConeKotlinType.render() 2022-06-29 16:50:03 +00:00
Mikhail Glukhikh 9a8fa300d7 Add test for KT-52020 2022-06-29 16:50:03 +00:00
Nikita Bobko 2c5bd4a065 Drop unused DefaultIdeTargetPlatformKindProvider class
KMA-455

This class was used in intellij but usages was dropped in
a55a62106e40f8545d654d5519576fa4e732d0fd (intellij repo).

DefaultIdeTargetPlatformKindProvider is useless because
`DefaultIdeTargetPlatformKindProvider.defaultPlatform` implementation
always returns `JvmPlatforms.defaultJvmPlatform`
2022-06-29 15:35:57 +02:00
Dmitriy Novozhilov 935f5c1180 [Parcelize] Fix registration of IR extension for K2 mode 2022-06-29 12:00:02 +00:00
Dmitriy Novozhilov 1a8496757e [Compiler] Mark all entrypoints to compiler API as experimental 2022-06-29 12:00:01 +00:00
Dmitriy Novozhilov 169e80e8c9 [Build] Cleanup build.gradle.kts for :compiler module 2022-06-29 12:00:01 +00:00
Dmitriy Novozhilov 65e240679e [FE] Move utility of parsing plugin options to :compiler:frontend.common
This is needed to be able to use this utility inside FIR part of IDE plugin
2022-06-29 12:00:00 +00:00
Dmitriy Novozhilov f587c02d38 [FE] Move ServiceLoaderLite to :compiler:frontend.common
This is needed to be able to use this class inside FIR part of IDE plugin
2022-06-29 12:00:00 +00:00
Dmitriy Novozhilov 441f3d202a [LL API] Introduce converters from plugin defined diagnostics to KtDiagnostics 2022-06-29 12:00:00 +00:00
Dmitriy Novozhilov 22dae9bff4 [FIR] Fix registration of multiple compiler plugins 2022-06-29 11:59:59 +00:00
Dmitriy Novozhilov 0c6a9d3eac [LL API] Provide proper way for automatic registration of compiler plugins 2022-06-29 11:59:59 +00:00
Dmitriy Novozhilov c979e1edcf [Plugins] Deprecate ComponentRegistrar
^KT-52665 In Progress
2022-06-29 11:59:58 +00:00
Dmitriy Novozhilov 8b42638afa [Plugins] Introduce new API for registering compiler plugins
Original `ComponentRegistrar` exposes Project to its registration method,
  so plugins should manually register extensions to it. To prepare for
  possible unbound compiler from Project API in future new  `K2ComponentRegistrar`
  introduced which provides registration method without Project at all
2022-06-29 11:59:58 +00:00
Ilya Chernikov bb996c1b27 Switch kotlin version to 1.8
with appropriate fixes in testdata, tests and other
places.
2022-06-29 10:20:30 +02:00
Dmitriy Novozhilov 7fa459044f [Test] Fix extracting path to standard libraries from incorrect places for external users 2022-06-29 06:41:07 +00:00
Ilmir Usmanov 09c9641e23 FE: Use safe call when searching for suspend modifier
The modifier does not exist, when the parameter type is typealias.

 #KT-35187 Fixed
2022-06-29 06:12:44 +02:00
Igor Yakovlev 1e0a705ba1 [WASM] Temporary disable wasm std test (until bootstrap) 2022-06-28 18:00:41 +00:00