Commit Graph

72493 Commits

Author SHA1 Message Date
Ilya Chernikov ef4fa3381d Pass provided script configuration to refining code
when script compilation configuration refinement
happening during parsing, the updated configuration
passed to the script compiler/REPL compile function
is now used.
#KT-44580 fixed
2021-02-09 15:22:55 +00:00
Dmitriy Novozhilov 6dd331d7e8 [FIR] Add tests for non exhaustive when as last expression of lambda
KT-44810
2021-02-09 16:04:42 +03:00
Dmitriy Novozhilov e54f31cc2f [IR] Remove useless init block from IrLazyFunction
This block was accidentally added in aaa3fa58 in debug purposes
2021-02-09 16:04:42 +03:00
Dmitriy Novozhilov 8f0e1035fa [FIR] Rename KEY and VALUE generics of FirCache to K and V 2021-02-09 16:04:42 +03:00
Dmitriy Novozhilov e7fdc18ced [FIR] Fix [JSP] Fast FIR tests run configuration 2021-02-09 16:04:41 +03:00
Dmitriy Novozhilov d7e3e83251 [FIR] Update testdata of FIR spec tests 2021-02-09 16:04:41 +03:00
Dmitriy Novozhilov 18bde2c542 [FIR] Reimplement when exhaustiveness checker to fir it's logic with FE 1.0 2021-02-09 16:04:41 +03:00
Dmitriy Novozhilov 2a1c9283a4 [FIR] Add useful util extensions for cone type 2021-02-09 16:04:41 +03:00
Dmitriy Novozhilov ad677046a8 [FIR] Replace isExhaustive flag with ExhaustivenessStatus object 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov 96038e4b32 [FIR] Support java sealed class interop 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov abd1c8fb30 [FIR] Move sealedInheritors declaration data to :fir:tree module 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov 8dd9d98129 [FIR] Implement checker for exhaustive when's in expression position 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov 3f715e671d [FIR] Fix checking for null exhaustiveness with expression of Nothing? type 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov 76f9830b47 [FIR] Fix checking for boolean exhaustiveness with || in branch 2021-02-09 16:04:40 +03:00
Dmitriy Novozhilov 6469900b5e [FIR] Fix forgotten light source element for if expression 2021-02-09 16:04:39 +03:00
Dmitriy Novozhilov 11ab37160e [FIR] Save info that when was used as expression 2021-02-09 16:04:39 +03:00
Dmitriy Novozhilov 490ef210ac [FIR] Support sealed class inheritors in multiple files 2021-02-09 16:04:39 +03:00
Dmitriy Novozhilov c8f9cc33ef [FIR] Pass all FirFiles to FirGlobalResolveProcessor.process 2021-02-09 16:04:39 +03:00
Dmitriy Novozhilov 38437fb036 [FIR] Rename session.firSymbolProvider to session.symbolProvider
to avoid visual conflicts with `session.firProvider`
2021-02-09 16:04:39 +03:00
Andrei Klunnyi e3c1aa599d KT-44487 [Sealed Interfaces]: sealed-inheritors-provider for MPP 2021-02-09 12:54:51 +00:00
Igor Chevdar 6f9bcf249b [IR] Supported inlining of adapted references + tests 2021-02-09 17:23:19 +05:00
Dmitriy Novozhilov 9724d81a49 [FIR] Support boolean elvis bound smartcasts
#KT-44511 Fixed
2021-02-09 15:20:36 +03:00
Dmitriy Novozhilov 2b088f1147 [FIR] Fix generating data class if there is non-property in primary constructor
#KT-44554 Fixed
2021-02-09 15:20:34 +03:00
Mikhael Bogdanov 30b5bfe767 Disable D8 checks for -jvm-target 15 tests 2021-02-09 12:34:56 +01:00
Mikhael Bogdanov 3dff225b98 Aligh test data with JDK 15 reflection output 2021-02-09 12:34:55 +01:00
Mikhael Bogdanov 21e9f67322 Add JvmTargetXOnJvm15 test suites 2021-02-09 12:34:55 +01:00
Mikhael Bogdanov 5c5fb0ae39 Add JvmTarget6OnJvm8 test suite 2021-02-09 12:34:55 +01:00
Ilmir Usmanov 8af9ce1e0b Minor. Ignore test on WASM 2021-02-09 12:31:14 +01:00
Ilmir Usmanov 275fef94fe JVM_IR. Do not mangle callable reference constructor call
#KT-44703 Fixed
2021-02-09 12:31:11 +01:00
Andrey Zinovyev 10cc86c975 [KAPT] Warn about usage of types from default package
Java doesn't support import from default package. 
We can't fix it, so we warn about it.
#KT-36743
2021-02-09 13:32:27 +03:00
Tianyu Geng 58d903c638 [FIR IDE] Make KtSmartcastProvider report resolved smartcast type 2021-02-09 11:19:58 +01:00
Roman Artemev d97a2b13c0 [Plugin API] Add API to load top level declaration by its signature
- request from JP Compose, #KT-44100
2021-02-09 11:56:20 +03:00
Roman Artemev ca6e1b8f1b Add box test for #KT-43831 2021-02-09 11:33:34 +03:00
Roman Artemev 79f986bb75 [IR] Fix IrType equality in case of complex variance
- reimplement type capturing on top of pure IrCaptureType
 - add captured type substitutor
 - fix #KT-43831
2021-02-09 11:33:34 +03:00
Roman Artemev 4ed93d3dee [IR] Add IrCapturedType into IR type system
- support it in TypeSystemContext
2021-02-09 11:33:33 +03:00
Georgy Bronnikov 9b6f95faa2 FIR: report lowering time in FullPipelineModularizedTest 2021-02-09 10:59:35 +03:00
Georgy Bronnikov 1664eec7e4 FIR: report lowering time from JvmIrCodegenFactory 2021-02-09 10:59:35 +03:00
Pavel Kirpichenkov 75954dd1a4 Minor: refactor extended compiler checks
Use an analysis flag instead of a stub language feature
2021-02-08 18:47:30 +03:00
Pavel Kirpichenkov 2a46da906c Provide additional information about missing supertypes
Add -X flag to report extra compiler diagnostics which migth break compatibility.
Use the flag to unconditionally check constructors without fear of
prematurely evaluating lazy supertypes.

KT-19234
KT-42404
KT-44583
2021-02-08 18:47:30 +03:00
Mikhail Glukhikh 4a381d4b83 FIR DFA: update receivers properly in case of single flow in merge point 2021-02-08 18:23:44 +03:00
pyos d96921e287 FIR2IR: collect annotations when expanding type aliases 2021-02-08 18:23:19 +03:00
Vladimir Dolzhenko 872effc21e Check declaration modifier for actual method to avoid freeze
Checking modifier aims to get rid of unnecessary resolve for methods in non MPP (the most) cases

Relates to #KTIJ-1200
2021-02-08 14:43:19 +00:00
Muhammad Hakim Asy'ari 3e17317f31 Update steps to install JDK 6 on Mac OS (#4052) 2021-02-08 16:41:38 +03:00
Mikhail Glukhikh d4b0688690 FIR: introduce delegate field initializers
Before this commit we initialized delegate fields in primary constructor,
that could provoke NPE in case delegate is used in initializer of
some property backing field.
Now we initialize delegate fields directly instead.
2021-02-08 14:28:27 +03:00
Mikhail Glukhikh 2cbdad0bb1 FIR2IR: insert implicit cast of receiver to Any for interface Any calls 2021-02-08 14:28:26 +03:00
Mikhail Glukhikh 1c210c2386 FIR: fix of super.methodOfAny resolve in case of one supertype 2021-02-08 14:28:25 +03:00
Mikhail Glukhikh 694d69fbfa FIR2IR: select return target inside accessor properly 2021-02-08 14:28:24 +03:00
Ilya Goncharov 19bffc694b [JS IR] Add test with chain export--not-export--export
^KT-44616 fixed
2021-02-08 13:41:16 +03:00
Ilya Goncharov 76b124a9c0 [JS IR] Method of any is exported
^KT-44616 fixed
2021-02-08 13:40:39 +03:00
Ilya Goncharov 7b4624aac4 [JS IR] Add exported method into exportNestedClass.kt
^KT-44616 fixed
2021-02-08 13:38:47 +03:00