Commit Graph

17 Commits

Author SHA1 Message Date
Svyatoslav Kuzmich 218c246111 [JS] Fix extra js function capturing 2021-02-04 15:41:21 +03:00
Roman Artemev c16b11a124 [JS IR BE] Fix throwable stuff to make exceptions similar to JVM 2020-10-12 15:22:43 +03:00
Roman Artemev ff093d363a [JS IR BE] Fix Throwable ancestor transformation
Make sure that `message` and `cause` are properly configured

 - synchronize IR BE and Legacy behaviour
 - fix corresponding IR lowering
 - fix JS IR core runtime
 - add test
 - fix KT-39964
2020-10-12 15:22:43 +03:00
Roman Artemev 8a810e2a5e [JS IR] Add runtime API to throw ISE in case of compiled code with errors 2020-09-01 14:53:07 +03:00
Alexander Udalov da6d904c6e Suppress code warnings in kotlin-stdlib 2020-08-20 20:30:34 +02:00
Svyatoslav Kuzmich 6792779281 [JS IR] Fix stack trace capturing in secondary constructors (KT-37563)
Call captureStack in primary constructors and generated factories
2020-06-22 11:50:14 +03:00
Vitaly 9ede8445e7 [JS BE] add runtime-function and intrinsics for es6-classes 2020-05-27 00:32:54 +03:00
Anton Bannykh e8a6ddceaa JS IR: hide runtime helpers from users 2020-04-28 16:40:07 +03:00
Zalim Bashorov 9e7f72382f [stdlib-js-ir] Remove BitUtils object and make all members toplevel
It works slightly better with IR DCE --
we get about 6% less code on box tests.
2020-03-11 12:54:41 +03:00
Roman Artemev 9871f8c579 [JS BE] Fix DCE to let it remove constant properties 2019-12-24 19:26:05 +03:00
Anton Bannykh 81699299f5 JS_IR: DCE
Could be enabled by toggling `-Xir-dce`

Box test output in js/js.translator/testData/out-min
2019-11-26 12:20:39 +03:00
Roman Artemev d4fb76c1da [JS IR BE] Fix overriding property of Throwable 2019-07-09 10:40:01 +03:00
Svyatoslav Kuzmich 675f01ee80 [JS IR BE] Set Throwable subtype name in extendThrowable function 2019-07-05 19:31:23 +03:00
Svyatoslav Kuzmich a2625c7bc8 [JS IR BE] Don't render null messages in Throwable
Set message property to 'undefined' to make Error.prototype.toString
skip it
2019-07-04 18:33:23 +03:00
Svyatoslav Kuzmich 94aebd0101 [JS IR BE] Proper support for String and Any constructors
Remove workarounds from codegen
2019-07-04 17:03:47 +03:00
Svyatoslav Kuzmich 918d470e1b [JS IR BE] Simplify throwable lowering.
- Make kotlin.Throwable class extenral
- Add runtime function 'extendThrowable' to use instead of delegating
  constructors to Throwable
2019-07-03 20:37:48 +03:00
Ilya Gorbunov eae1813ead stdlib-js(-v1/-ir): rename source files to avoid duplicates in sources
Prohibit having duplicates in sources jar and rename those source files,
that clash with the same named source files coming from
the common js source root.

Relates to KT-31965
2019-06-18 20:03:04 +03:00