Ilya Kirillov
d8a3dacdc5
FIR: return back supertypeRefs list recreation
2021-03-09 15:41:42 +01:00
Vladimir Ivanov
fd02802028
[Native] Export KDoc into generated native header
2021-03-09 16:50:23 +03:00
Jinseong Jeon
6427117a35
FIR CFG: correct edge label from a node that returns Nothing
...
If it's not within a try/catch/finally, that should be an uncaught
exception path.
^KT-45327 Fixed
2021-03-09 14:44:42 +03:00
Jinseong Jeon
d8fb54c6bd
Reproduce KT-45327: false positive MUST_INITIALIZED_OR_BE_ABSTRACT after conditional exitProcess
2021-03-09 14:44:42 +03:00
Alexander Udalov
628d75c7cd
JVM: fix EnclosingMethod information for SAMs in inline lambdas
...
Pass parentContext to SamWrapperCodegen from the outside instead of
using the one from parentCodegen. The difference is that in case of an
inline lambda, we're creating an InlineLambdaContext whose parent is a
ClosureContext, but the codegen for that lambda has that latter
ClosureContext as its context. So the getNonInlineOuterContext call in
SamWrapperCodegen.generateInnerClassInformation wasn't able to identify
that this is a context of a lambda that needs to be skipped, and
generated it as EnclosingMethod, which caused Java reflection to fail
because once that lambda was inlined, it was removed and thus didn't
make it to runtime.
#KT-44827 Fixed
2021-03-09 11:43:11 +01:00
Mads Ager
7dbb0c7d20
[IR] Make IrGetObjectValue copyable to avoid duplicate IR nodes.
...
Fixes KT-45170
2021-03-09 09:48:16 +03:00
Ilmir Usmanov
e79c9a3618
Extend LVT record of alive variables to end of next suspension point
...
Otherwise, arguments of suspend call become invisible in async stack
trace
#KT-44714
2021-03-08 23:56:40 +01:00
Ilmir Usmanov
b6bb8a576e
Make start label of LVT record the point where variable becomes alive
...
Otherwise, there will be overlapping LVT records, which leads to
removal of the whole LVT by R8.
#KT-44714 Fixed
2021-03-08 23:56:39 +01:00
Ilmir Usmanov
e17b7f01b6
Do not remove dead variables' LVT records
...
Also, extend liveness of alive variable to nearest suspension points
#KT-44714
2021-03-08 23:56:36 +01:00
Alexander Udalov
6ddca4a592
Add KClass.isValue to kotlin-reflect
...
#KT-44782 Fixed
2021-03-08 21:22:40 +01:00
Mikhael Bogdanov
4d51d71699
Fix EXPLICIT_OVERRIDE_REQUIRED_IN_MIXED_MODE message
2021-03-08 17:52:52 +00:00
Mikhael Bogdanov
3568eba1b2
Use actual implementation instead of inherited one in -Xjvm-default diagnostics
2021-03-08 17:52:52 +00:00
Mikhael Bogdanov
71c134e54f
Fix checker for -Xjvm-defaults
2021-03-08 17:52:51 +00:00
Alexander Udalov
8b8262096c
Fix testKt44814 by adding an IR dump
...
It's supposedly needed because of the `// DUMP_IR` directive.
2021-03-08 17:32:13 +01:00
Alexander Udalov
9970851684
Restore writing bytecode version to metadata for LV < 1.5
...
#KT-45323 Fixed
2021-03-08 11:18:54 +01:00
Alexander Udalov
a2200b5386
Revert "Do not write bytecode version to class file"
...
This reverts commit c6f5ce6837 .
#KT-45323
2021-03-08 11:18:54 +01:00
scaventz
9a7ef11043
Report a readable diagnostic on empty -J argument in CLI
2021-03-06 03:14:11 -08:00
scaventz
81a495b494
Fix the NullPointerException when pathname does not name a parent.
2021-03-06 01:50:40 -08:00
Mikhail Glukhikh
037505d9f2
FIR IDE: regenerate diagnostics
2021-03-06 09:22:35 +03:00
Mikhail Glukhikh
7eb9b1188f
FIR: implement helpers for diagnostic suppression on elements children
2021-03-06 09:22:35 +03:00
Mikhail Glukhikh
15c3269e38
FIR: don't report error on inline nested classes
2021-03-06 09:22:35 +03:00
Mikhail Glukhikh
1e4d7ff690
Fix LightTreePositioningStrategies.DECLARATION_NAME
2021-03-06 09:22:35 +03:00
eugenpolytechnic
f6e564ffa6
FIR: introduce inline classes checks
2021-03-06 09:22:34 +03:00
Ilya Gorbunov
9cc8f44390
Support mod and floorDiv extensions in constant evaluator
...
Ignore evaluation tests for floorDiv and mod with FIR for now.
2021-03-05 23:46:57 +03:00
Ilya Gorbunov
58e6f775bb
Rename test of rem operator evaluation
2021-03-05 23:46:57 +03:00
Mads Ager
e5631addf3
[IR] Move annotations from original to new constructor declarations.
...
LocalDeclarationsLowering did not move annotations when creating
a new constructor declaration, thereby losing the annotations.
Fixes KT-45298
2021-03-05 12:24:38 -08:00
Mads Ager
965c118521
[JVM IR] Make upper bounds check recursive for ieee Equals.
...
Fixes KT-44402
2021-03-05 12:22:54 -08:00
Alexander Udalov
566f97ae3e
JVM IR: remove dependency of 'backend.jvm' on 'psi2ir', 'ir.serialization.jvm'
...
Add a new module 'backend.jvm.entrypoint' which depends on psi2ir and
contains code that runs psi2ir + JVM IR backend with serialization
implementations.
Hopefully this will allow to compile these modules in parallel and
reduce the build time.
2021-03-05 20:46:33 +01:00
Alexander Udalov
5e0860ca14
IR: move PsiSourceManager, PsiErrorBuilder to ir.backend.common
2021-03-05 20:46:33 +01:00
Alexander Udalov
bec4d1903b
IR: move PsiFileEntry to ir.tree, rename to PsiIrFileEntry
2021-03-05 20:46:33 +01:00
Alexander Udalov
1f8de46b3c
JVM IR: do not depend on StubGeneratorExtensions in backend
...
Move most of the implementation from JvmGeneratorExtensions to
JvmGeneratorExtensionsImpl. The latter implements
StubGeneratorExtensions from psi2ir, and doing so helps to remove direct
dependency on this part of psi2ir from backend.
2021-03-05 20:46:33 +01:00
Alexander Udalov
22d269a0a8
Minor, rename JvmGeneratorExtensions.kt -> JvmGeneratorExtensionsImpl.kt
...
To keep git history for this file after the subsequent commit, where
most of the implementation is moved to JvmGeneratorExtensionsImpl.
2021-03-05 20:46:33 +01:00
Alexander Udalov
f332192de8
IR: remove SourceManager, make PsiSourceManager a singleton
2021-03-05 20:46:33 +01:00
Mikhael Bogdanov
8ff0b1e243
Reports warning on super calls in public-api inline functions
2021-03-05 18:45:07 +00:00
Alexander Udalov
027df41740
Add test which runs Kotlin compiler in parallel
...
This will be useful in diagnosing issues like KT-45007 in the future.
#KT-45007
2021-03-05 17:58:42 +01:00
Alexander Udalov
e7e17cdaa9
Revert "Fix KotlinCoreEnvironment projectCount disposable"
...
This reverts commit 99a6bdeec7 .
#KT-45007 Fixed
2021-03-05 17:40:39 +01:00
Vladimir Dolzhenko
36ff952a0f
Ignore when failed to get file text
...
Relates to #KTIJ-706
2021-03-05 17:12:56 +01:00
Andrei Klunnyi
a0b901b23a
Revert "[FIR]: sealed hierarchy processor for IDE"
...
This reverts commit e6ccdff2
2021-03-05 16:37:47 +01:00
Igor Yakovlev
b744f41c0d
[ULC] Fix annotations invalid parents
...
Fixed #KT-45287
2021-03-05 14:33:10 +01:00
Igor Yakovlev
179cf303da
[ULC] Fix annotations with no site for ctor
...
Fixed #KT-45291
2021-03-05 14:33:10 +01:00
Roman Artemev
9bdfbc948c
[KLIB] Support assignable value parameters in deserializer
...
- fix KT-44945
2021-03-05 13:47:07 +03:00
Andrei Klunnyi
e6ccdff2f7
[FIR]: sealed hierarchy processor for IDE
...
From now on sealed declarations get resolved with the help of
FirIdeSealedHierarchyProcessor. This change entails correct IDE side
check for sealed when exhaustiveness.
2021-03-05 10:20:19 +00:00
Dmitriy Novozhilov
aa829c2321
[FIR2IR] Fix using default values of annotation arguments
2021-03-05 13:00:12 +03:00
Dmitriy Novozhilov
ca26c193ae
Make all hierarchies of JavaAnnotationArgument sealed
2021-03-05 13:00:12 +03:00
Dmitriy Novozhilov
1f6ce874a1
Don't fail on unsupported default values of java annotations
2021-03-05 13:00:12 +03:00
Dmitriy Novozhilov
745aa620d0
Reformat annotationArgumentsImpl.kt
2021-03-05 13:00:11 +03:00
Dmitriy Novozhilov
bd7689d381
[FIR] Properly compute default arguments of java annotations
2021-03-05 13:00:11 +03:00
Dmitriy Novozhilov
8324f499cd
[FIR] Fix serializing annotation metadata on setters value parameters
2021-03-05 13:00:11 +03:00
Jinseong Jeon
8368812432
Minor cleanup: avoid vague util names
2021-03-05 10:06:22 +03:00
Jinseong Jeon
8b24f4b5c6
Minor cleanup: place modifier strategies close to each other
2021-03-05 10:06:22 +03:00