Alexander Udalov
3f034e8b67
Enable lightweight lambdas (aka invokedynamic) since 2.0
...
#KT-45375 Fixed
#KT-58173 Open
2024-02-08 19:46:18 +00:00
Ivan Kylchik
0af4ef8ee9
Fix typo in test name: inlinInDefault -> inlineInDefault
2023-03-14 20:47:43 +00:00
Ivan Kylchik
b812a6c6f5
Ignore tests that are currently not working with IR inliner
2023-03-14 20:47:42 +00:00
Ivan Kylchik
bb401c39d9
Add several new SMAP tests
...
Some of them are still failing and suppose to be
fixed later
2023-03-14 20:47:39 +00:00
Ilya Chernikov
5b3816cce5
Test infra: refactor IGNORE_BACKEND directive
...
treat it as a general one, introduce *_K1 and *_K2 variants for
more specific ignoring
2022-11-12 16:28:23 +01:00
Steven Schäfer
2acfb3a41f
JVM IR: Avoid direct lambda invokes in inline tests
2022-07-14 23:24:18 +02:00
Georgy Bronnikov
109bdb9572
Adjust tests for FirSerializeCompileKotlinAgainstKotlin
2022-05-19 12:02:43 +02:00
Georgy Bronnikov
5605463ecf
Introduce IGNORE_BACKEND_FIR_MULTI_MODULE directive
2022-05-19 12:02:43 +02:00
Ivan Kylchik
c7435ba760
Replace all occurrences of WITH_RUNTIME with WITH_STDLIB
...
We are going to deprecate `WITH_RUNTIME` directive. The main reason
behind this change is that `WITH_STDLIB` directive better describes
its meaning, specifically it will add kotlin stdlib to test's classpath.
2021-11-17 15:26:38 +03:00
Mads Ager
41aa0a7c7f
[FIR] Fix line number differences between psi2ir and fir2ir.
2021-11-01 15:43:13 +03:00
Ivan Kylchik
f4bbcdc013
[TESTS] Move global directives outside file scope
2021-10-25 00:14:19 +03:00
Dmitry Petrov
851980e36f
JVM_IR KT-45103 optimize direct invoke for lambdas and callable refs
2021-05-18 22:20:12 +03:00
pyos
e6d923f65c
FIR: rename HIDDEN to INVISIBLE_REFERENCE
...
Some of them should be INVISIBLE_MEMBER though
2021-04-21 16:18:21 +03:00
Dmitriy Novozhilov
49c2bfe637
[Test] Enable SMAP dump handler in boxInline tests
2021-02-02 17:53:53 +03:00
Dmitriy Novozhilov
64a300bfcd
[TD] Update testdata according to previous commit
2021-02-02 17:53:52 +03:00
Dmitriy Novozhilov
8973e3f362
[TD] Update fir directives in boxInline tests
2021-02-02 17:50:07 +03:00
Dmitriy Novozhilov
6a2796b067
[Test] Fix source maps in testdata according to KT-37704
2021-01-28 13:19:29 +03:00
Mikhael Bogdanov
de00f72fa3
Generate linenumber for inline call site in case of implicit iterator/hasNext/next calls in for loop
...
Otherwise -1 is generated in smap
2021-01-21 12:04:09 +01:00
Mikhael Bogdanov
91717cdcdd
Perform inline checks in IR tests
2021-01-20 15:23:09 +01:00
Alexander Udalov
9e357354fb
Add JVM/JVM_IR mixed compilation tests for compileKotlinAgainstKotlin/boxInline
2020-09-07 19:41:37 +02:00
pyos
76c34a07b2
JVM: use 1 as a synthetic line number for @InlineOnly lambdas
...
The source path already marks it as synthetic.
2020-05-25 20:03:56 +02:00
pyos
25e1fb8502
JVM: map synthetic line numbers through the SMAP
...
This is necessary so that IDEA does not ignore the line number.
2020-05-25 20:03:56 +02:00
pyos
d17a18f96d
JVM: do not write trivial SMAPs to classes outside inline funs
...
where trivial == those that map the file to itself.
2020-05-25 20:03:56 +02:00
pyos
86b28b95ca
JVM: keep call site markers when inlining lambdas into objects
...
A follow-up for KT-35006:
fun f() = foo {
bar()
}
inline fun foo(crossinline x: () -> Unit) = { x() }()
inline fun bar() = TODO()
does not provide the option to navigate to bar's call site at all.
2020-05-19 18:33:27 +02:00
pyos
5feadd56ef
JVM: parse KotlinDebug when regenerating anonymous objects
2020-05-19 18:33:27 +02:00
pyos
1fe7ef6521
JVM: separate the two kinds of source mappers
...
* a writing source mapper has `mapLineNumber(line, file, class)` that
inserts a new SMAP entry and returns a fake line number from it;
* a copying source mapper has `mapLineNumber(line)` that uses an
existing SMAP to resolve the line number and call the former method
on a different source mapper;
* those two types are disjoint.
2020-05-19 18:33:27 +02:00
Mikhail Bogdanov
461c368ee0
Minor. Unmute test
2020-04-16 13:49:48 +02:00
Kristoffer Andersen
7ec4c9990a
[JVM] Improve debug step behavior around lambdas.
...
- Add tests to clarify problematic behavior
- Avoid line numbers on return instructions of lambdas without explicit returns
2020-04-15 14:33:49 +02:00
Mikhail Bogdanov
1772f20d48
Minor. Add smap test for multifile facade
2020-04-08 07:26:55 +02:00
pyos
9334327bbf
JVM_IR: unmute two more tests fixed by #3106
2020-04-08 07:04:16 +02:00
pyos
b3e124ad66
Add a test where classes call inline functions from each other
2020-04-08 07:04:16 +02:00
Mads Ager
03fb49bb38
[JVM_IR] Improve debugging behavior of inline functions
...
Specifically, this commit improves the stepping behavior of the IR
backend around functions with defaults.
- Improved line numbers in the default handler itself for better
stepping when inlined.
- Improved source information on default arguments
- Improved test coverage of stepping behavior in old and IR backends.
Improves the stepping behaviour around inline methods with default
arguments. In particular, we now accurately step through the
evaluation of default arguments, but do _not_ spuriously show the exit
from the $default handler.
2020-04-07 16:52:45 +02:00
pyos
e98bdc6f8e
JVM: preserve call site markers when inlining lambdas
...
and default functions into their own stubs.
Fixes #KT-35006
2020-03-31 16:06:57 +02:00
pyos
9d21800d8f
JVM: fix SMAP range extension logic
...
If `mapLineNumber` was called in non-monotonic order, e.g. N then N+2
then N+1, the first two calls created a range that spans [N; N+2] but
the third call did not reuse it.
2020-03-31 16:06:57 +02:00
pyos
be37e7135a
Add a test for SMAPs with interleaved files
2020-03-25 14:03:32 +01:00
pyos
4558d48481
JVM: add a language feature to omit *E between SMAP strata
...
Fixes #KT-37704
2020-03-25 10:33:59 +01:00
Jinseong Jeon
2352b1fec5
JVM_IR: use fresh source map when generating lambda body for inline.
2020-03-19 08:28:38 +01:00
Zalim Bashorov
179ec41a6b
[JS BEs] Generate tests for whole "codegen/boxInline"
2020-03-12 17:22:33 +03:00
Ilmir Usmanov
22de20e7e5
JVM_IR: Generate PUBLIC constructor for suspend lambda
...
if the lambda is inside inline function.
2020-03-02 14:03:35 +01:00
Ilmir Usmanov
6ede10c1ca
JVM_IR: Minor. Add test for SMAP of inner object/lambda of inline suspend function
2020-01-20 16:00:36 +01:00
Steven Schäfer
0da4b06074
psi2ir: Fix return insertion
...
We should only insert a return statement at the end of a lambda or
function if the final statement is used as an expression (slice
USED_AS_RESULT_OF_LAMBDA and USED_AS_EXPRESSION).
2019-10-31 11:13:44 +03:00
pyos
d3992826e4
JVM_IR: discard parameter annotations in anonymous object constructors
2019-10-14 14:54:44 +02:00
pyos
06c00f4d9e
Unmute some JVM_IR inlining tests
2019-10-08 17:19:41 +02:00
Georgy Bronnikov
7ede26e8f4
IrCompileKotlinAgainstInlineKotlin tests
2019-09-06 09:19:57 +03:00
Mikhael Bogdanov
1eda42cb88
JVM_IR. Generate SMAP information for anonymous classes
...
#KT-28092 Fixed
2019-08-08 12:02:50 +02:00
Steven Schäfer
efb938a7c8
(Un)mute tests
2019-07-31 11:18:44 +02:00
Mikhael Bogdanov
ec6904afd1
Minor. Fix test data
2019-05-06 17:34:02 +02:00
pyos
90f11211d3
JVM_IR: wrap performInline in enterIntoInlining/exitFromInliningOf
2019-05-06 16:23:28 +02:00
Mikhael Bogdanov
eb1bfac83f
Minor. Fix test data
2019-04-08 16:23:00 +02:00
Mikhael Bogdanov
2a3a9bb5fc
Support properties reificaton
2019-04-08 13:10:25 +02:00