pyos
a1f0c6208c
Add a test from KT-51950
2022-06-13 11:58:15 +02:00
Pavel Mikhailovskii
bcd8a28d4c
KT-47823 IR.JVM Fix handling of for loop ranges with inline types and break/continue/return
2022-06-10 18:42:28 +00:00
Pavel Mikhailovskii
ecb3cc193c
KT-51883 Don't use "-" in generated unique lifted declaration names
2022-06-10 18:36:04 +00:00
pyos
526e46cffc
FIR: fix some errors in local variable assignment analyzer
...
* wrong method was called from FirDataFlowAnalyzer.exitFunctionCall;
* map from function to affected properties should be keyed by symbol,
not FirFunction, as the latter may change;
* arguments of `return` and assignment statements should be visited,
as they may contain lambdas.
2022-06-10 09:43:48 +03:00
pyos
9968fa252a
FIR: fork flow on function entry, restore receivers on exit
...
^KT-52680 Fixed
2022-06-10 09:42:02 +03:00
Denis.Zharkov
3ba11711d2
Adjust test data after reverting fix for KT-35811
...
(see previous commit)
^KT-52684 Fixed
2022-06-09 15:44:36 +00:00
Denis.Zharkov
9caa60d389
Revert "KT-35811: Type parameter angle brackets followed by equal sign are parsed incorrectly if whitespace is missing"
...
This reverts commit ba5c85d6
^KT-52684 Related
2022-06-09 15:44:36 +00:00
Denis.Zharkov
67f9025f9e
Add test data for parsing of complicated <..> and <..>= combinations
...
^KT-52684 Related
^KT-8263 Related
2022-06-09 15:44:35 +00:00
Mikhail Zarechenskiy
372879b8e7
[FE 1.0] Don't fail with exception on unresolved type with type argument
...
^KT-50223 Fixed
2022-06-09 08:03:35 +00:00
pyos
27c51f5f88
JVM_IR: skip SAM lambdas when computing enclosing method of objects
...
This is what Java 15+ does, and it permits accessing captured type
parameters via reflection. The alternative is to emit generic signatures
on the lambda methods, but that was disabled and I have no clue why.
^KT-52417 Fixed
2022-06-08 23:59:58 +02:00
Pavel Mikhailovskii
f81d47bad6
KT-46797 Generate generic signatures for suspendImpl
2022-06-08 16:15:08 +02:00
Steven Schäfer
dbb6144ab0
JVM IR: Avoid boxing in generic floating point equality (KT-48635)
2022-06-08 15:38:06 +02:00
Roman Golyshev
8fca9f41eb
[FIR IDE] Correctly check declarations' modalities in SamResolver
...
Modality might be null before the declaration itself is resolved to
`STATUS`
^KT-52667 Fixed
2022-06-07 21:14:24 +00:00
Igor Yakovlev
f996278171
[WASM] Support for mjs universal launcher
2022-06-07 20:59:03 +00:00
Dmitriy Novozhilov
5d0655247f
[NoArg] Add implementation of plugin for FIR
2022-06-07 14:12:18 +00:00
Dmitriy Novozhilov
22ebea8174
[FIR] Support FIR version of all-open plugin
2022-06-07 14:12:14 +00:00
Dmitriy Novozhilov
4003ca0691
[FE] Add ability to set compatibility of plugin with K2 in ComponentRegistrar
2022-06-07 14:12:14 +00:00
Dmitriy Novozhilov
67589b1b09
[FIR] Don't report TAILREC_ON_VIRTUAL_MEMBER_ERROR on private declarations
2022-06-07 14:12:13 +00:00
Pavel Mikhailovskii
65b2cee913
KT-23397 Optimize out field for property delegate when it's safe (JVM)
2022-06-07 10:46:01 +00:00
Denis.Zharkov
41dd00c241
FIR: Use outer scope for annotation arguments resolution
...
^KT-41980 Fixed
2022-06-06 15:18:05 +03:00
Denis.Zharkov
eae673233b
FIR: Rework FirRegularTowerDataContexts
...
- Get rid of SPECIAL mode (just left REGULAR and class-related instead)
- Clear naming
- Restore contexts after lambda/callable reference are processed
The test has been failing before this change because after
callable reference is resolved, its tower data context has been left
erroneously in the SPECIAL-related entry
2022-06-06 09:39:29 +00:00
Roman Golyshev
166c771e1b
[FIR IDE] Ensure resolve to CONTRACTS phase in ReturnTypeCalculator
...
If we want to analyse some function's call, we need to know about its
contracts, otherwise resolving the following code would be broken.
Computing return type of function is a prerequisite to using it in any
sensible way, so it's the best place to resolve it to CONTRACTS
KT-50733
2022-06-06 09:14:37 +00:00
Ilya Gorbunov
e14ac2a062
Test kotlin-repeatable annotations on Android
...
(except for type-use annotations)
2022-06-04 10:39:37 +00:00
Mikhail Glukhikh
6fc27c22f4
K1:report warning on OptIn usages inside SAM constructor #KT-47708 Fixed
2022-06-02 15:36:58 +00:00
Nikolay Lunyak
62ec19bda2
[FIR JS] Fix current tests
2022-06-02 13:47:33 +00:00
Nikolay Lunyak
be9e97d044
[FIR] Introduce ConeDynamicType
2022-06-02 13:47:23 +00:00
Ilmir Usmanov
f922684169
Minor. Add regression test
...
#KT-52561 Fixed
2022-06-02 13:26:24 +00:00
Denis.Zharkov
461d91a10e
FIR: Rework checking dispatch receivers applicability
...
Using `ownerLookupTag` might be wrong in case of private constuctors
of inner classes: their owner is an Inner class, but expected
dispach receiver is Outer
2022-06-01 16:02:31 +00:00
Denis.Zharkov
67e6687e89
FIR: Fix FP error on a call to constructor of a private inner class
...
Do not check dispatch receiver applicability when checking visibility
for containing class of a callee constructor
2022-06-01 16:02:30 +00:00
Denis.Zharkov
c1904004c4
FIR: Fix case when smartcast receiver is used for call to private method
...
^KT-54432 Fixed
2022-06-01 16:02:30 +00:00
Denis.Zharkov
ccc32b4e3b
FIR: Refine visibility check for private methods defined in a class
...
- use-site should be contained within the class that owns callee symbol
- class-representative of dispatch receiver value
should be exactly the same as a container class of a callee (not its subtype)
2022-06-01 16:02:29 +00:00
Pavel Mikhailovskii
3b5179686e
KT-52592 Fix NPE from KProperty.getExtensionDelegate on property delegated to another property; make $delegate methods private
2022-06-01 14:02:28 +00:00
Sergej Jaskiewicz
e03747ea7d
[JS IR] Introduce the GENERATE_INLINE_ANONYMOUS_FUNCTIONS feature flag
2022-06-01 09:02:31 +00:00
Roman Golyshev
01ce499bb2
[FIR] Unify some special names to make code more uniform
2022-06-01 00:11:17 +04:00
Victor Petukhov
b472ccd358
[FE 1.0] Introduce deprecation of inferred type variable into a declared upper bound within a builder inference call
2022-05-31 14:13:29 +00:00
Victor Petukhov
848075192c
[FE 1.0] Don't use BuilderInferenceSubstitutionConstraintPosition for declared upper bound constraint with no substituted upper bound
...
It leads to further infer type variable into those upper bounds which is forbidden
Substituted upper bounds is ok because specific substituted types came from constraints of other proper positions, or if specific substituted type is from declared upper bound too, then there should be another declared upper bound with no substitution
^KT-51464 Fixed
^KT-47986 Fixed
2022-05-31 14:13:28 +00:00
Victor Petukhov
f5f398788d
[FE 1.0] Add checker to report "unsupported range until operator" on declaration itself
2022-05-31 08:42:57 +00:00
Victor Petukhov
c266303197
[FE 1.0] Introduce "range until operator" language feature, and report errors on its usages till 1.8
2022-05-31 08:42:57 +00:00
Victor Petukhov
de9d1dc536
[Parser] Add additional parsing tests
2022-05-31 08:42:56 +00:00
Victor Petukhov
96d1f89836
[BE] Support until operator in back-ends
2022-05-31 08:42:56 +00:00
Victor Petukhov
2378979a99
[FE JS] Support until operator in WRONG_OPERATION_WITH_DYNAMIC error
2022-05-31 08:42:55 +00:00
Victor Petukhov
0b25ce4de9
[FE] Support resolve of until operator to rangeUntil
...
^KT-52420 Fixed
2022-05-31 08:42:55 +00:00
Victor Petukhov
19136019e4
[Parser] Support of parsing until operator
...
^KT-52419 Fixed
2022-05-31 08:42:54 +00:00
Pavel Mikhailovskii
2ceccec2b8
KT-52551 Create a static initialization section in case of delegation to a property reference from a file class
2022-05-30 14:16:18 +00:00
Ivan Kochurkin
792aa24a04
[FIR] Throws by star import wins builtin Throws, ^KT-52407 Fixed, ^KT-52517 Fixed
2022-05-29 23:41:27 +03:00
Ivan Kochurkin
e004c8e2d6
[FIR2IR] Pass value parameter name to createDefaultSetterParameter if it exists
2022-05-29 23:41:25 +03:00
Ivan Kochurkin
feb3f41108
[FIR] Fix resolve inside lambda
...
The lambda is passed to extension function with type parameters
that defined inside this lambda
^KT-52197
^KT-52190 Fixed
2022-05-29 23:41:25 +03:00
Ivan Kochurkin
ad7c213ab2
[FIR] Initialize type for annotation arguments during deserialization
...
Get rid of IrErrorTypeImpl creating in FIR2IR
2022-05-29 23:41:23 +03:00
Ivan Kochurkin
0ef043b074
[FIR2IR] Consider property init value from nested class, ^KT-52057 Fixed
2022-05-29 23:41:23 +03:00
Alexander Udalov
a7f4981fe5
Normalize virtual file paths to prevent duplicate sources
...
#KT-52465 Fixed
2022-05-27 23:40:57 +02:00