Roman Golyshev
496e4dd0e3
KTIJ-26867 [AA] Allow resolve from write action in KtFirReferenceResolver
...
`KtReference` might be resolved from anywhere, even
from the write action - the call site might not know
anything about Kotlin, and might not be able to
somehow prevent the `inaccessible analysis session`
exception from being thrown. That's why we
have to be permissive here.
^KTIJ-26867 Fixed
2023-09-01 14:20:03 +02:00
Ilya Goncharov
0f40b2adce
[Gradle, wasm] Hack for mixed mode with js, wasmJs and wasmWasi
...
^KT-61623 fixed
2023-09-01 11:53:04 +00:00
strangepleasures
cc60618e86
KGP IT: do not run a failing test with class loader cache
2023-09-01 11:26:17 +00:00
Alexander Shabalin
958d613911
[K/N] Remove code for deprecated targets from runtime ^KT-59008
2023-09-01 10:48:07 +00:00
Dmitriy Novozhilov
e4a51dfa1b
[Serialization] Don't report errors on properties from supertypes
...
^KT-53926 Fixed
2023-09-01 09:35:43 +00:00
Dmitriy Novozhilov
b4bc659008
[FIR] Update documentation of AbstractPredicate about matching local declarations
...
^KT-52449 Obsolete
2023-09-01 09:35:43 +00:00
Nikolay Lunyak
b25a67a50e
[FIR] Prohibit statement-like expressions in expression context
...
^KT-61067 Fixed
2023-09-01 09:30:28 +03:00
Alexander Udalov
5c19cb3fcb
[KAPT4] KT-51982 Implement Kapt4AnalysisHandlerExtension, add KAPT CLI and Gradle IT
...
Co-authored-by: Alexander Udalov <Alexander.Udalov@jetbrains.com >
2023-08-31 22:19:13 +00:00
Alexander Udalov
d50d36f16c
Kapt+JVM_IR: add regression test for KT-61212
...
#KT-61212
2023-08-31 17:58:04 +00:00
Dmitrii Krasnov
1af7aba26e
Bump Kotlin/Native version in KGP to 1.9.30-dev-1903
2023-08-31 17:39:47 +00:00
Dmitrii Krasnov
0191a15d96
migrated NativeDownloadAndPlatformLibsIT to junit 5 and gradle TestKit
2023-08-31 17:39:47 +00:00
Ilmir Usmanov
168076766f
Minor. Fix test
2023-08-31 15:55:06 +00:00
Ilmir Usmanov
6c13250a08
KAPT3: Use another class in com.sun.tools.javac.main
...
Instead of CommandLine use Option, since CommandLine was moved or
removed from JDK 21.
#KT-60507 Fixed
2023-08-31 15:55:06 +00:00
Ilmir Usmanov
62effc49fa
KAPT3: Suppress useless cast, since it is not useless on JDK 21
2023-08-31 15:55:06 +00:00
Donald Duo Zhao
a8fcdddf24
Move to use reflection to access JDK8 APIs
...
Currently, KAPT3 uses JDK internal API to build Java AST.
Since the API is internal, it has changed in newer JDKs.
So, for them, use reflection to access new API.
#KT-59349 Fixed
2023-08-31 15:55:06 +00:00
Ilya Kirillov
56910b70a3
[Analysis API] fix "KotlinIllegalStateExceptionWithAttachments: expected as maximum one expect for the actual"
...
^KT-61597 fixed
2023-08-31 15:19:29 +00:00
Roman Golyshev
f39153b6e6
KT-61568 [FIR][AA] Add one more testcase for AllCandidatesResolver
2023-08-31 14:59:53 +00:00
Abduqodiri Qurbonzoda
9352e40d54
Wasm Enum.hashCode() is not final #KT-61614
...
Merge-request: KT-MR-11938
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com >
2023-08-31 14:31:56 +00:00
Mikhail Glukhikh
3ff2c7d6f7
K2: introduce custom Enum.entries migration checkers
...
Related to KT-56623, KT-56587
#KT-59344 Fixed
2023-08-31 13:29:02 +00:00
Mikhail Glukhikh
e0d68fc93e
K2: introduce FirEnumEntriesRedeclarationChecker (KT-59344)
2023-08-31 13:29:01 +00:00
Mikhail Glukhikh
d028f9ec95
K2: add stubs for enum entries deprecation diagnostics (KT-59344)
2023-08-31 13:29:01 +00:00
Alexander.Likhachev
652ff54835
[Gradle] Print kapt worker classpath properly
2023-08-31 13:14:49 +00:00
Alexander.Likhachev
77b9860021
[Gradle] Make KaptTask.kaptPluginOptions an input of the task
...
#KT-58326 Fixed
2023-08-31 13:14:49 +00:00
Alexander.Likhachev
3a246d3a1d
[Gradle] Add an integration test for KT-58326
2023-08-31 13:14:49 +00:00
Pavel Kunyavskiy
91e96e9f31
[Fir2Ir] Introduce testing with IrFakeOverrideBuilder
...
^KT-61514
2023-08-31 13:12:15 +00:00
Pavel Kunyavskiy
bf9cae6410
[Fir2Ir] Support rebuilding fake overrides over IR
...
^KT-61514
2023-08-31 13:12:15 +00:00
Pavel Kunyavskiy
44c2a749c9
[Ir common] Introduce symbol table api to remove entries
...
^KT-61514
2023-08-31 13:12:15 +00:00
Nikolay Lunyak
0d19942d2c
[FIR] Make reporting of local class diagnostics more consistent with K1
...
It would be nice to report more appropriate diagnostics at the
corresponding places, but right now it's more important to
fix greenness-redness problems. Plus, this is already how K1 works.
^KT-59900 Fixed
2023-08-31 13:07:00 +00:00
Ilya Kirillov
9b114335fb
[stdlib] fix stdlib-common highlighting in K2 IDE plugin
...
K2 IDE Plugin uses only a partial set of built-ins.
It only has declarations which are not present in
the JVM stdlib as classfiles.
Because of that, some major declarations like
`kotlin.Unit` are missing,
so resolution inside kotlin stdlib common modules does not work.
Because of incorrectly resolved stdlib,
highlighting and resolution in other files in the kotlin project does not work.
This commit adds source versions of stdlib declarations
(`/core/builtins/src/kotlin/`) to the common stdlib as a source-set
for IDE import.
This way all declarations in stdlib common module are properly resolved.
The approach might be incorrect as it might introduce possible redeclaration
conflicts between common and platform stdlib sources
as `/core/builtins/src/kotlin/` source-set is also registered as a source-set for
platforms.
2023-08-31 12:51:47 +00:00
Brian Norman
997e062de9
[FIR] Check top-level property initialization via CFG
...
Now that files have a CFG, use it to validate properties are initialized
correctly. Update FirTopLevelPropertiesChecker to collect initialization
info for the property being checked - similar to
FirMemberPropertiesChecker - and validate proper initialization.
#KT-56683 Fixed
#KT-58531 Fixed
2023-08-31 12:50:52 +00:00
Brian Norman
b55fda0c55
[FIR] Create CFG for files to track top-level property initialization
...
In order to properly analyze top-level property initialization, a
control-flow graph must be created for FirFiles. This change adds the
foundation for the file CFG and updates body resolve to create the CFG.
Checking the CFG for proper initialization is separated into a following
change to ease code review.
KT-56683
2023-08-31 12:50:52 +00:00
Dmitrii Gridin
0b7eb32064
[FIR] FirSupertypeResolverVisitor: use symbol API instead of ClassId version
...
In Low Level FIR we have a simplified version of getFirClassifierContainerFileIfAny
without a scope search
^KTIJ-26848
2023-08-31 12:34:46 +00:00
Dmitriy Novozhilov
de68ec7cd5
[FIR] Properly report SEALED_INHERITOR_IN_DIFFERENT_MODULE
...
^KT-46031 Fixed
^KT-59804 Fixed
2023-08-31 12:32:25 +00:00
Anton Bannykh
387898056a
[JS] Report K2 diagnostics before Fir2IR
...
^KT-60531 fixed
2023-08-31 12:15:08 +00:00
Brian Norman
3590f0aa03
[FIR] Check type alias visibility after constructor visibility
...
#KT-61576 Fixed
2023-08-31 12:01:30 +00:00
Evgeniy.Zhelenskiy
6ede1bcf85
[IR] Reduce unnecessary allocations
2023-08-31 10:43:30 +00:00
Kirill Rakhman
0121686a7f
[RAW FIR] Use KtFakeSourceElementKind.WrappedDelegate in LT
2023-08-31 10:19:33 +00:00
Kirill Rakhman
21f8ba1706
[FIR] Don't report DEPRECATION on self-access in delegated property
...
#KT-60682
2023-08-31 10:19:33 +00:00
Kirill Rakhman
411210b520
[RAW FIR] Use range as source of desugared loop-related statements
2023-08-31 10:19:33 +00:00
Kirill Rakhman
61259ef34b
[FIR] Report missing DEPRECATION on fake sources
...
#KT-60682
2023-08-31 10:19:33 +00:00
Kirill Rakhman
4e041494be
[FIR] Report DEPRECATION when Java declaration is deprecated in javadoc
...
#KT-60682
2023-08-31 10:19:33 +00:00
Dmitrii Gridin
99307f97e9
[Low Level FIR] introduce service for incoming psi modifications processing
...
This service encapsulates all logic and simplifies future evolution
^KT-60610
2023-08-31 10:06:43 +00:00
Dmitriy Novozhilov
6169834bb3
[FIR] Make FirResolvedDeclarationStatus.modality non nullable
...
^KT-58764 Fixed
2023-08-31 09:38:44 +00:00
Dmitrii Krasnov
8299fffae2
Added possibility to create a custom usable KotlinCompile task without using internals ownModuleName and moduleName
...
#KT-60541 Ready for Review
2023-08-31 09:37:21 +00:00
Ilya Kirillov
103ebb0ab4
[kotlin] fix AssertionError: Alien file! in IJ test
...
We should not cache `VirtualFile` per-application
2023-08-31 08:55:17 +00:00
Roman Golyshev
1766c68e9c
[FIR][AA] Rely more on isInBestCandidates flag KtFirReferenceShortener
...
After the KT-61568 has been fixed, `isInBestCandidates`
correctly works in more cases, and can be more
reliably used in `KtFirReferenceShortener`
^KTIJ-26808 Fixed
^KTIJ-26840 Fixed
2023-08-31 08:45:34 +00:00
Kirill Rakhman
ac102dedac
[IR Actualizer] Fix fake-override generation in actual A -> common B -> actual C hierarchy
...
... where C defines a member x and A overrides the member x
#KT-61166 Fixed
2023-08-31 07:52:02 +00:00
Kirill Rakhman
293474ee50
[FIR2IR] Remove unused return value of processOverriddenPropertySymbols
2023-08-31 07:52:01 +00:00
Abduqodiri Qurbonzoda
64fd4ac510
Native Enum.hashCode() is not final #KT-61507
...
Merge-request: KT-MR-11937
Merged-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com >
2023-08-30 21:34:46 +00:00
Alexander Shabalin
bd797ed503
[K/N] Run stdlib tests only in normal mode ^KT-61259
2023-08-30 17:34:34 +00:00