Commit Graph

6 Commits

Author SHA1 Message Date
Kirill Rakhman 03fc0fd381 [FIR] Remove FirLambdaArgumentExpression
It's not really necessary if the information about if the lambda was a
trailing lambda can be directly saved in FirAnonymousFunctionExpression.

Removing the FIR node uncovered a couple of bugs
(UNINITIALIZED_ENUM_ENTRY, ERROR_IN_CONTRACT_DESCRIPTION) that were
caused by assuming that a lambda is always a trailing lambda.

#KT-66124
2024-03-13 17:05:48 +00:00
Dmitrii Gridin d5cfea330b [LL FIR] support parameters resolution
Script parameters now can be resolved independently of the script.
But, as parameters are part of the script, their resolve will be called
before the script.

^KT-66276 Fixed
2024-03-07 12:50:59 +00:00
Ilya Chernikov 266447120d K2 scripting: treat default import similarly to K1
namely, add them to importing scopes directly and according to the
schema used for other implicit imports, rather than adding them
to the regular script file imports. See KT-65982 for explanation.
#KT-65982 fixed
2024-02-23 22:03:44 +00:00
Ilya Chernikov 9037975758 K2 Scripting: Skip base class params from resolution scope
The base class in scripting considered obsolete and therefore supported
via some ad-hoc mechanisms. In particular parameters to the base class
c-tor are passed via script provided properties. But in combination
with the resolution logic, this leads to issues described in KT-60452
This commits filters out such parameters from script resolution
scope and avoids this problem for now.
Bot it should be noted that proper diagnostics for properties shadowing
should still be implemented - see #KT-65809
#KT-60452 fixed
2024-02-23 22:03:44 +00:00
Dmitrii Gridin 58ad26ee5b [LL FIR] make script initializers independent
Now we can resolve all script declarations independently

^KT-65344 Fixed
2024-02-13 14:58:31 +00:00
Yan Zhulanow 08727bf0be [Analysis API] Add more ContextCollector tests inspired by dependentCopy
As the on-air analysis is obsolete, related tests are going to be
deleted. Here we add cases not yet covered by 'ContextCollector' tests.
2024-01-18 17:12:28 +00:00