Dmitry Petrov
cb1b9c2ccf
IR testData: IrSimpleFunction.isOperator
2019-11-29 13:53:05 +03:00
Roman Artemev
a343a57207
[IR] Refactor ir infrastructure
...
- Remove range-based uniq id indexes using to link built ins
- Limit KotlinType usages, replace them with corresponding IrType
2019-11-12 20:45:11 +03:00
Steven Schäfer
733c7579aa
Normalize names of temporary variables in IrTextTests
2019-11-05 14:58:47 +03:00
Steven Schäfer
a90ac2438d
Set correct field visibility in psi2ir
2019-08-28 19:41:11 +02:00
Dmitry Petrov
7170439517
IR: '!!' is generated as 'CHECK_NOT_NULL' intrinsic
...
```
fun <T : Any> CHECK_NOT_NULL(x: T?): x =
if (x != null) x else throw NullPointerException(...)
```
This allows to compile both Kotlin/JVM and Kotlin/JS effectively.
2019-08-14 11:16:10 +03:00
Dmitry Petrov
bdec8b04e8
Minor: trim in RenderIrElementVisitor
2019-07-31 10:37:35 +03:00
Dmitry Petrov
339291b01f
psi2ir: update testData
2019-06-26 09:39:16 +03:00
Dmitry Petrov
760806a1ac
IR: IMPLICIT_DYNAMIC_CAST
...
Generate IMPLICIT_DYNAMIC_CAST for implicit casts from `dynamic` to `T`
2019-06-26 09:39:16 +03:00
Zalim Bashorov
6634d7ab15
[psi2ir] Minor: dynamicWithImplicitCast.kt -> dynamicWithSmartCast.kt
2019-04-04 17:14:04 +03:00
Zalim Bashorov
57a6b53780
[psi2ir] Add tests for implicit casts "to" and "from" dynamic type
2019-04-04 17:14:03 +03:00
Dmitry Petrov
a5c95275f0
IR: get rid of descriptors in DumpIrTree
2019-03-21 11:23:51 +03:00
Dmitry Petrov
9a82f926a1
IR: descriptor-less rendering of IR elements (work in progress)
2019-03-21 11:23:51 +03:00
Dmitry Petrov
e49eae528c
IR: don't use descriptors in rendering (work in progress)
...
There's some descriptor-based code remaining. Need some more work on IR.
2019-03-21 11:23:51 +03:00
Ting-Yuan Huang
6bbb0269b1
IR: Set when.origin for IrIfElseImpl
...
Change-Id: I38510b59e3dc936baadbfe3ef2702990493815e5
2019-03-13 08:48:20 +01:00
Dmitry Petrov
e1fdf0aa43
KT-29959 fix IR generation for 'd.m = e'
2019-02-19 09:59:42 +03:00
Dmitry Petrov
6aff53204f
psi2ir: support dynamic infix calls ('foo bar 42' is 'foo.bar(42)')
2019-02-14 16:03:11 +03:00
Dmitry Petrov
77cbd10f9c
psi2ir: don't generate temporaries in dynamic array augmented assignment
...
In constructs such as 'd[i] += x', where both indexed get and indexed
set are dynamic calls, it's safe to generate augmented assignment body
directly, without temporary variables for array ('d') and index ('i').
Note that corresponding IntermediateValue's are OnceExpressionValue's,
which would throw an exception if this assumption is violated.
2019-02-14 16:03:11 +03:00
Dmitry Petrov
5b4b22a8b6
psi2ir: additional tests for dynamic expressions: '?:', '!!'
2019-02-14 16:03:11 +03:00
Dmitry Petrov
cf29dce4c2
pri2ir: dynamic unary & binary expressions
...
NB1 Not every dynamic unary or binary expression is translated to
dynamic operator expressions literally. For example, assignments and
increments can have safe calls in LHS, which require some extra logic.
NB2 There are some open design questions left regarding how dynamic
expressions should actually be translated.
2019-02-14 16:03:11 +03:00
Dmitry Petrov
fbbe4f6e92
psi2ir: dynamic array element get/set
2019-02-14 16:03:11 +03:00
Dmitry Petrov
9a2bd5f4e6
psi2ir: dynamic member simple assignment/augmented assignment/++/--
2019-02-14 16:03:11 +03:00
Dmitry Petrov
fc76d0970b
psi2ir: Implicit casts with 'dynamic'
2019-02-14 16:03:11 +03:00
Dmitry Petrov
3c8f52b436
psi2ir: simple dynamic member calls
2019-02-14 16:03:11 +03:00
Dmitry Petrov
ddb1ea2047
psi2ir: dynamic member access ('d.x', 'd?.x')
2019-02-14 16:03:11 +03:00
Dmitry Petrov
763e72603a
Mark implicit 'invoke' calls with origin INVOKE
2018-10-18 10:59:24 +03:00
Dmitry Petrov
ad9953724f
Basic infrastructure for psi2ir tests with JS front-end
2018-10-18 10:59:24 +03:00