Mikhail Glukhikh
51cd1b2d6f
[minor] Fir2IrVisitor: reformat
2023-03-16 18:07:36 +00:00
Mikhail Glukhikh
43a0e7ecbd
FIR2IR: add test for KT-57221
2023-03-16 18:07:35 +00:00
Artem Kobzar
758b0ab457
[K/JS] Fix Windows test run with a long test name
2023-03-16 16:48:53 +00:00
nataliya.valtman
37eefc2a05
KT-57296 And backward compatibility with old Idea versions
2023-03-16 16:30:56 +00:00
Dmitriy Novozhilov
6af1c550b6
Update copyright
2023-03-16 15:16:32 +00:00
Dmitriy Novozhilov
b6a41c6d93
[CLI] Extract classes of compiler configuration from :compiler:cli to the separate module
...
Those classes mainly include KotlinCoreEnvironment and its dependencies
This change is needed for two reasons:
1. Splitting of some common configuration of compiler from logic of CLI
makes code structure more clean
2. There is a need to add dependency on `:analysis:analysis-api-standalone`
to `:compiler:cli`, because FIR analogue of AnalysysHandlerExtension uses
services from it. But the problems is that standalone AA itself depends
on classes for compiler configuration, which leads to circular
dependency between those modules. Extracting configuration to
`:compiler:cli-base` solves the problem
2023-03-16 15:16:32 +00:00
Dmitriy Novozhilov
507ef3e951
[FIR] Properly handle declarations from other source sessions in FirPredicateBasedProvider
...
^KT-57083 Fixed
2023-03-16 15:13:19 +00:00
Denis.Zharkov
644391a8e0
K2: Fix Java enhancement when jsr305.jar is not in classpath
...
In that case, when loading Java, we just remember the name of `@Nonnull`
argument (javax.annotation.meta.When), and then use it during enhancement
^KT-56656 Fixed
2023-03-16 14:43:05 +00:00
Denis.Zharkov
955b8e1490
K2: Introduce new FIR node kind FirFromMissingDependenciesNamedReference
...
The basic idea is that during deserialization/loading compiled
Java classes, there might be some of the dependencies absent that
are referenced from enum arguments in annotations.
Such situation is not considered as totally ill-formed, thus supporting
it, allowing to read the names of mentioned in the annotation argument
might be useful for Java enhancement
^KT-56656 In Progress
2023-03-16 14:43:05 +00:00
Denis.Zharkov
157c260fda
Add test data with current behavior for KT-56656
2023-03-16 14:43:05 +00:00
Denis.Zharkov
bcbe26287a
Adjust CLI tests for JSR305 annotations being extracted
...
See the previous commits
2023-03-16 14:43:04 +00:00
Denis.Zharkov
13febaf978
Adjust tests for JSR305 annotations being extracted
...
See the previous commits
2023-03-16 14:43:04 +00:00
Denis.Zharkov
c86c96f5e5
Extract javax.annotations from third-party/foreign-annotations
...
Later, JSR 305 related classes will be used to be compiled in a separate
jar that will be used to compile Java, but would be absent in the
Kotlin classpath in ForeignAnnotations-related tests
It's necessary to have a proper test for KT-56656
2023-03-16 14:43:04 +00:00
aleksandrina-streltsova
34c739789f
[AA] Fix rendering for type variable with "Type is not inferred"
...
It is required to show type variable name instead of ERROR in completion
^KTIJ-20913
2023-03-16 13:57:56 +00:00
Dmitrii Gridin
bccf1aaff0
[SLC] symbolLightUtils: cleanup code
2023-03-16 11:42:22 +00:00
Dmitrii Gridin
4dbc6654b0
[SLC][tests] rename stopIfCompilationErrorDirectivePresent to isTestAgainstCompiledCode for clarity
2023-03-16 11:42:21 +00:00
Dmitrii Gridin
71299f1d13
[SLC] cover case with invalid java identifier as annotation argument
...
^KT-56868 Fixed
^KT-57328
2023-03-16 11:42:21 +00:00
Artem Kobzar
948c511284
[K/JS] Rework ES modules part with squashed JsImport and right renaming strategy inside import/export statements
2023-03-16 10:28:39 +00:00
Svyatoslav Kuzmich
3c0048bfd8
[Wasm] Add typealias diagnostic test cases
2023-03-16 09:12:08 +00:00
Svyatoslav Kuzmich
76b4498399
[Wasm] IDL bindings improvements
...
- Generated types extend JsAny
- Use JsAny instead of Dynamic
- Use JsArray instead of Array
- Use JsNumber, JsString and JsBoolean in JsAny context
- Refactor dictionary constructor functions
2023-03-16 09:12:08 +00:00
Svyatoslav Kuzmich
2a10cf3de2
[Wasm] Dukat: use IDL conversion API directly without dukat CLI
...
Copy unmodified convertToModel.kt from dukat
2023-03-16 09:12:08 +00:00
Svyatoslav Kuzmich
1208a26fc4
[Wasm] Use JsAny, JsHandle and other Js* types in stdlib and kotlin-test
2023-03-16 09:12:07 +00:00
Svyatoslav Kuzmich
d6886d69ec
[Wasm] Add internal JsPrimitive annotation
...
Before external classes could only represent JS object types and are
type-checked with `instanceof`.
@JsPrimitive allows external classes to represent primitive types with
`typeof` checks.
2023-03-16 09:12:07 +00:00
Svyatoslav Kuzmich
1e91fe155b
[Wasm] Restrict types allowed in JS interop
...
- Prohibit Any, Array and other unsupported non-external types in JS
interop context
- Add K1 diagnostic
- Update BE testdata
^KT-57136 Fixed
2023-03-16 09:12:07 +00:00
Svyatoslav Kuzmich
bb05c8528f
[Wasm] Fix KtDeclarationWithBody.hasValidJsCodeBody
...
Empty bodies are not valid jsCode bodies.
2023-03-16 09:12:06 +00:00
Yan Zhulanow
c66f1a12cb
[LL API] Handle 'KtScript' consistently in file-based provider
2023-03-15 19:22:43 +00:00
Pavel Kunyavskiy
8f4c6eae2f
[K/N] Get rid of ArrayAsList class, use .asList() instead
...
^KT-57137
2023-03-15 18:03:14 +00:00
Nikolay Lunyak
967ddb8bb0
[FIR] KT-57211: Generate FirArrayOfCall for unsigned types
...
^KT-57211 Fixed
Merge-request: KT-MR-9216
Merged-by: Nikolay Lunyak <Nikolay.Lunyak@jetbrains.com >
2023-03-15 17:05:09 +00:00
Yahor Berdnikau
c17668a225
Add Android project level compiler options DSL
...
Works the same as JVM project compiler options DSL. 'android
.kotlinOptions' now configures compilerOptions from extension basically
behaving same way as newly added DSL.
^KT-57159 Fixed
2023-03-15 15:39:09 +00:00
Yahor Berdnikau
edc6194737
Fix reporting compiler stats
...
Now it should report actual values for languageVersion, apiVersion and
progressiveMode for any compilation invocation.
^KT-57159 In Progress
2023-03-15 15:39:08 +00:00
Yahor Berdnikau
dfec9efbb0
Add JVM project level compiler options DSL
...
These options are used as initial convention values for compilerOptions
in target compilations.
^KT-57159 In Progress
2023-03-15 15:39:08 +00:00
Yahor Berdnikau
6509b0201c
Add method to sync options from one instance to another as convention
...
^KT-57159 In Progress
2023-03-15 15:39:08 +00:00
Yahor Berdnikau
4d4e5f4701
Split compiler options implementation and helper methods
...
Such split allows to reuse default implementation for different
use-cases. Helpers, in this case, allows to do manipulations with
options where required.
^KT-57159 In Progress
2023-03-15 15:39:07 +00:00
Roman Golyshev
2086c5348b
KTIJ-24438 Add missing K2 and cli artifacts to bundled compiler plugins
...
Those artifact will be bundled to Kotlin K2 Plugin and would be used
as a replacement for user-supplied plugins in order to avoid binary
incompatibilities
2023-03-15 15:18:59 +00:00
Nikolay Lunyak
d639215084
[FIR] KT-57095: Allow X? -> * assignments in unification
...
^KT-57095 Fixed
Merge-request: KT-MR-9180
Merged-by: Nikolay Lunyak <Nikolay.Lunyak@jetbrains.com >
2023-03-15 13:56:51 +00:00
Anton Lakotka
9de86c03b7
[Gradle] Move createFatFrameworks call to KotlinMultiplatformPlugin.apply
2023-03-15 13:51:12 +00:00
Anton Lakotka
b993064818
[Gradle] Remove workaround assertion after fixing KT-55751
2023-03-15 13:51:11 +00:00
Anton Lakotka
a2e5fa64dc
[Gradle] Use SingleActionPerProject instead runOnceAfterEvaluated
...
To create fat frameworks for all targets.
That should be called only single time
KT-55751 Verification Pending
KT-56450 Verification Pending
2023-03-15 13:51:11 +00:00
Anton Lakotka
92cc13961f
[Gradle] Add user-specific attributes to host-specific metadata elements
...
KT-55751 Verification Pending
KT-56450 Verification Pending
2023-03-15 13:51:11 +00:00
Anton Lakotka
427ef8fc47
[Gradle] Don't create fat frameworks from single binary framework
...
KT-55751 Verification Pending
2023-03-15 13:51:10 +00:00
Anton Lakotka
371e1205c0
[Gradle] Filter non-existing consumable configurations
...
^KT-55751 Verification Pending
2023-03-15 13:51:10 +00:00
Anton Lakotka
fff24378f1
[Gradle] Add test to check consumable configurations have unique
...
attributes set.
^KT-55751 Verification Pending
2023-03-15 13:51:10 +00:00
Anton Lakotka
9804ea80c4
[Gradle] Update tests to not have non-distinguishable targets
...
^KT-55751 Verification Pending
2023-03-15 13:51:09 +00:00
Anton Lakotka
b9f0ad0e58
[Gradle] Report warning when targets are not distinguishable
...
^KT-55751 Verification Pending
2023-03-15 13:51:09 +00:00
Mikhail Glukhikh
58959951d3
K2: fix CCE during bound conversion for Java raw Kotlin-based type
...
#KT-56630 Fixed
2023-03-15 13:40:49 +00:00
Pavel Kunyavskiy
d1e0a432a5
Regenerate test files
2023-03-15 11:55:29 +01:00
Alexander Korepanov
e3402fcc87
[K2 JS] Do not load transitive dependencies for building K2/JS klibs
...
^KT-57262 Fixed
2023-03-15 10:49:54 +00:00
Pavel Kunyavskiy
62fb3df7f0
[K/N] Disable scope initialization on constant access
...
^KT-57098
2023-03-15 09:03:19 +00:00
Alexander Shabalin
e6297f92fa
[K/N] Issue deprecation warning when using legacy MM
...
Merge-request: KT-MR-9091
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com >
2023-03-15 08:22:37 +00:00
Vladimir Sukharev
5bd0a1a0ba
Disable some tests due to open issues and incompatibility with K1/MPP
...
Merge-request: KT-MR-9206
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-03-15 06:55:27 +00:00