Mikhail Glukhikh
4d49bdb8ca
K2: add a black box test to confirm KT-53718 now works properly (JVM IR only)
...
Related to: KT-57584, KT-58110
2023-11-15 09:33:05 +00:00
Mikhail Glukhikh
4b1368409d
K2: add a black box test to confirm KT-55705 now works properly
2023-11-15 09:33:05 +00:00
Mikhail Glukhikh
f2ef41dbbd
K2: add a black box test for KT-58874 to confirm work also in runtime
2023-11-15 09:33:03 +00:00
Kirill Rakhman
ed53d45307
[FIR] Add TODO for deprecation and fix of error-level nullable arguments of warning-level annotated Java type
...
#KT-56989
#KT-63208
2023-11-15 08:43:55 +00:00
Kirill Rakhman
2005446296
[FIR] Preserve enhanced mutability when nullability was enhanced for warning
...
#KT-56989
2023-11-15 08:43:55 +00:00
Kirill Rakhman
a63ec9efdc
[FIR] Implement warnings for java nullability upper bound violation
2023-11-15 08:43:55 +00:00
Kirill Rakhman
2df1e9dde6
[FIR] Implement warnings for java nullability type mismatch on override
...
#KT-56989
2023-11-15 08:43:55 +00:00
Kirill Rakhman
a6fdeeb7df
[FIR] Implement warnings for java nullability type mismatch
...
#KT-56989
2023-11-15 08:43:55 +00:00
Kirill Rakhman
1ecbc094ec
[FIR] Save warning-level enhanced types to an attribute
...
#KT-56989
2023-11-15 08:43:55 +00:00
Kirill Rakhman
ef96912573
[FIR] Apply withNullability to attributes with cone types
...
#KT-56989
2023-11-15 08:43:55 +00:00
Kirill Rakhman
7910e8ad24
[FIR] Implement a special type of attribute that contains a cone type that can be transformed
2023-11-15 08:43:55 +00:00
Kirill Rakhman
8ebd2fd1b7
[FIR] Implement add in AbbreviatedTypeAttribute
2023-11-15 08:43:55 +00:00
Kirill Rakhman
ad4d021cbf
[FIR] Reformat AbbreviatedTypeAttribute
2023-11-15 08:43:55 +00:00
Kirill Rakhman
51a3fe367c
[Tests] Fix deadlock caused by eager initialization in JspecifyMarksCleanupPreprocessor
2023-11-15 08:43:55 +00:00
Nikolay Lunyak
80cccce8d0
[FIR] Use the proper processAll* functions for CONFLICTING_OVERLOADS
...
The `*leaf*` functions were
introduced due to my false
assumption. The normal processing
functions only collect leafs
already. `*leaf*`s are bad, because
they don't cache anything.
The change in
AbstractFirOverrideScope reflects
KT-63290, and is needed to avoid
duplicate `CONFLICTING_OVERLOADS`
and `VIRTUAL_MEMBER_HIDDEN`.
2023-11-15 07:56:32 +00:00
Nikolay Lunyak
008703c1dc
[FIR] Fix parameters constraints in FirDeclarationCollector<D>.collect
2023-11-15 07:56:32 +00:00
Nikolay Lunyak
44d6d10233
[FIR] Only check conflicting callables that may clash with declared ones
...
This change improves performance, as
checking callables via scopes in
`4e587157` turns out to be quite
slow, and it also prevents some redundant
diagnostics.
2023-11-15 07:56:32 +00:00
Nikolay Lunyak
9e57aba448
[FIR] Add a test for KT-26045
...
^KT-26045 Fixed
Merge-request: KT-MR-13023
Merged-by: Nikolay Lunyak <Nikolay.Lunyak@jetbrains.com >
2023-11-15 07:52:11 +00:00
Stanislav Ruban
b2fb37043d
[tests] Regenerate configurations for diagnostic tests
2023-11-14 17:58:21 +00:00
Stanislav Ruban
c7caca8ccd
[tests] Refactor code examples relevant to exploration of KT-22004
2023-11-14 17:58:20 +00:00
Stanislav Ruban
d0958068c9
[tests] Add code examples from exploration of KT-22004
2023-11-14 17:58:20 +00:00
Brian Norman
ed4a778aa7
[FIR2IR] Convert data class properties of type dynamic for hashCode
...
Properties of type dynamic within a data class cause compilation to fail
when converting FIR to IR. This is because dynamic types do not have a
proper backing class for symbol lookup. However, dynamic types can just
be considered of type Any for hashCode calculations.
^KT-63094 Fixed
2023-11-14 17:45:04 +00:00
Dmitriy Dolovov
d8eee222af
[KLIB] API 4 ABI: Add information about backing field annotations
...
^KT-62259
2023-11-14 17:20:45 +00:00
Dmitriy Dolovov
01f072bb7d
[KLIB] API 4 ABI: Add tests for public members of EEC
2023-11-14 17:20:45 +00:00
Nikolay Lunyak
425d5e808b
[FIR] Link some tests with issues
...
Just in case.
^KT-59874
2023-11-14 15:19:33 +00:00
Nikolay Lunyak
41c5934d4e
[FIR] Don't forget to ignore hidden imports
...
^KT-59874
2023-11-14 15:19:33 +00:00
Nikolay Lunyak
c656a83a02
[FIR] Don't miss non-const annotation args
...
This code with `b()` crashes the JVM
backend.
^KT-59822 Fixed
^KT-59874
2023-11-14 15:19:33 +00:00
Nikolay Lunyak
5a1a23afac
[FIR] Don't miss annotations on inits
...
^KT-59874
2023-11-14 15:19:33 +00:00
Nikolay Lunyak
63f461a6cd
[FIR] Don't miss annotations on for loops variables
...
^KT-59874
2023-11-14 15:19:32 +00:00
Nikolay Lunyak
d03039b949
[FIR] Don't generate property fields when context receivers are present
...
^KT-59874
2023-11-14 15:19:32 +00:00
Nikolay Lunyak
4b67a504be
[FIR] Only support @ExtensionFunctionType on true functional types
...
^KT-59874
2023-11-14 15:19:32 +00:00
Mikhail Glukhikh
be5a27dd6b
K2: add test to confirm KT-56409 now works properly
2023-11-14 14:25:13 +00:00
Mikhail Glukhikh
cf9bd44cf7
K2: add test to confirm KT-54139 now works properly
2023-11-14 13:33:18 +00:00
Svyatoslav Kuzmich
1c230c8f27
[Wasm] Port WasmImport/WasmExport checker to K2 (KT-56849)
2023-11-14 12:24:10 +00:00
Dmitrii Gridin
28895a2613
[FIR] FirAnnotationArgumentsTransformer: fix scope problem with type parameters
...
We should wrap outer declaration to avoid FirTowerDataMode.CLASS_HEADER_ANNOTATIONS
^KT-63396 Fixed
2023-11-14 10:46:43 +00:00
Dmitrii Gridin
2ee9fcab9b
[FIR] add diagnostic test for annotations inside type parameters
...
^KT-63396
2023-11-14 10:46:43 +00:00
Artem Kobzar
bec434d534
[K/JS] Save nullability from the original type of value parameters ^KT-63013 Fixed
2023-11-14 10:40:07 +00:00
Aleksandra.Arsenteva
83c90d0e4f
Add one more test for KT-61959
...
Generate FE tests
2023-11-14 10:09:54 +00:00
Alexander Udalov
39fda3535a
IR: fix internal visibility check in override builder
...
In case there are Java sources in the module, K2 creates two instances
of `FirModuleDescriptor` with the same name: one for Kotlin sources, one
for Java sources. When building fake overrides in IR, it's important to
understand that those are the same module. Currently it's done by
comparing the names, but in the future it may be improved in KT-62534.
The changed test was in fact unrelated to KT-61805, and the problem
there was rather that no fake override was created for internal property
`schemeState` in `InspectionProfileModifiableModel`.
2023-11-14 09:45:06 +00:00
Alexander Udalov
54705e5afc
IR: copy context receiver parameters count in FakeOverrideCopier
...
#KT-63430 Fixed
2023-11-13 21:36:22 +00:00
Iaroslav Postovalov
a3b55cf758
[IR] Drastically simplify the hierarchy of IR origins
...
IrStatementOriginImpl and IrDeclarationOriginImpl were made final
classes to simplify the creation of them (a delegate provider was
added) and to optimize performance when comparing the origins by type
and name
2023-11-13 17:56:09 +00:00
Mikhail Glukhikh
e747793e62
FIR2IR: simplify applyAssigningArrayElementsToVarargInNamedForm a bit
2023-11-13 16:23:26 +00:00
Mikhail Glukhikh
4913c38e98
FIR2IR: insert spread for named argument against primitive vararg
...
#KT-60312 Fixed
2023-11-13 16:23:26 +00:00
Mikhail Glukhikh
4abce54748
K2: reproduce KT-60312
2023-11-13 16:23:26 +00:00
Mikhail Glukhikh
53ab32e0fb
Rename: ConeTypeVariableType.lookupTag -> typeConstructor
2023-11-13 15:10:48 +00:00
Mikhail Glukhikh
1ceec4d6d7
K2: make type variable based types not class like
...
#KT-57921 Fixed
#KT-62420 Fixed
2023-11-13 15:10:48 +00:00
Mikhail Glukhikh
5c56f0ef77
K2: drop obsolete TODO about use-site targeted annotations
...
See comments in KT-59824
#KT-59824 Obsolete
2023-11-13 13:59:32 +00:00
Mikhail Glukhikh
9903b70e0a
K2: add test to confirm KT-58874 now works properly
...
#KT-58874 Obsolete
2023-11-13 12:26:28 +00:00
Pranav
6c7963fe47
fix: Fix memory leak in ZipImplementation with -Xuse-fast-jar-file-system
...
When using the compiler with `-Xuse-fast-jar-file-system` enabled, the compiler causes memory leak in ZipImplementation class at MappedByteBuffer.contentsToByteArray method since the Inflater used to deflate zip/jar files, isn't released/ended after the task.
2023-11-13 10:04:39 +00:00
Chris Povirk
72c9378500
Fix error message for -Xjspecify-annotations.
...
The message currently claims that you can pass the value "disable," but
in fact the value it means is "ignore."
2023-11-13 09:59:27 +00:00