Igor Yakovlev
82455c849d
[WASM] Lazy properties initialization
2022-01-05 13:12:32 +01:00
Igor Yakovlev
e58d4163ad
[WASM] Add std methods for collections
2022-01-05 13:12:32 +01:00
Igor Yakovlev
c9a92d71ae
[WASM] Add kotlin.math tests
2022-01-05 13:12:32 +01:00
Igor Yakovlev
adee0f1cb0
[WASM] Add kotlin.math implementation
2022-01-05 13:12:32 +01:00
Igor Laevsky
cfcbe9e1e2
[Wasm] Better preserve IR types after inlining
2022-01-01 20:04:44 +02:00
Igor Yakovlev
72e360be83
[WASM] More optimal way to keep regex decomposition table
2021-12-09 00:57:55 +01:00
Igor Yakovlev
ea060dcf8a
[WASM] Implement lazy with UnsafeLazyImpl
2021-12-07 21:33:34 +03:00
Igor Yakovlev
d55e16a030
[WASM] Regex std implementation
2021-12-07 21:33:31 +03:00
Igor Yakovlev
86daff8ae8
[WASM] Fix invalid exception type for IOOB array access
2021-12-07 21:33:24 +03:00
Igor Yakovlev
34c6abe0bd
[WASM] Add Long.toString(radix) implementation
2021-12-07 21:33:14 +03:00
Igor Yakovlev
73ca478fbd
[WASM] Add string to double conversion to Stdlib
...
This version is not completely correct - there is some IEEE rouding issue that, apparently, require to implement different algorithm with BigIntegers implementation.
2021-12-07 21:33:07 +03:00
Igor Yakovlev
9408499da9
[WASM] Add std text implementations
2021-12-07 21:32:59 +03:00
Ilya Gorbunov
4386a800c8
KT-49721 Avoid matching from the same position after a zero-width match
...
In JS, RegExp can return a match before the specified start index,
if it has matched at that index, but it is in the middle of a surrogate
pair. Account for that when advancing to the next position after
a zero-width match so that it doesn't get to the middle of SP.
2021-11-29 17:02:06 +00:00
Ilya Goncharov
f48436b35e
rra/ilgonmic/eager-like-native
...
[JS IR] Leave JsEagerInitialization until bootstrap update
[JS IR] Fix js stdlib api
[JS IR] Change annotation on eager initialization in sources
[JS IR] Make eager initialization consistent with native
Merge-request: KT-MR-5030
2021-11-22 12:45:37 +00:00
Svyatoslav Kuzmich
f833fc4bcb
[Wasm] Default parameter values for external functions
...
+ import top-level external functions wrapped in lambdas
2021-11-17 19:28:14 +00:00
Igor Yakovlev
ec9fcce1bc
[WASM] Add hashCode, equals and toString to KClass and KType implementations
2021-11-15 19:53:48 +03:00
Igor Yakovlev
ee7f4c7278
[WASM] Implementation typeOf support
2021-11-15 19:53:48 +03:00
Igor Yakovlev
39a389c49a
[WASM] Implementation qualifiedOrSimpleName
2021-11-15 19:53:47 +03:00
Igor Yakovlev
ce360bb10b
[WASM] Implementation of Class references
2021-11-15 19:53:46 +03:00
Igor Laevsky
c7cfa97748
[Wasm] Implement Any::hashCode()
2021-11-15 18:26:46 +03:00
Igor Laevsky
9e00a2c5b4
[Wasm] Implement platform random in stdlib
2021-11-15 18:26:45 +03:00
Svyatoslav Kuzmich
08362e8b38
[Wasm] Support defineExternally
2021-11-12 18:44:46 +03:00
Igor Laevsky
22c161bcee
[Wasm] Run unit tests for the wasm stdlib (fail on verifier for now)
2021-11-03 16:23:02 +03:00
Igor Laevsky
46b56c7642
[Wasm] Improve string constructor in stdlib
2021-11-03 16:23:01 +03:00
Igor Laevsky
cb10bd3a95
[Wasm] Port stdlib and kotlin.test build to wasm gradle plugin
2021-11-03 16:23:01 +03:00
Svyatoslav Kuzmich
766377a041
[Wasm] Remove WasmForeign annotation
...
No longer needed since external interfaces are supported
2021-10-28 18:47:38 +03:00
Svyatoslav Kuzmich
4fc461a2ff
[Wasm] Imporove external interface support
...
* Support boxing/unboxing when casting to Any
* Support ===, equals, hashCode, toString
* Support adapting String in interop boundary
2021-10-23 01:26:12 +03:00
Svyatoslav Kuzmich
baa53b5cf3
[Wasm][Stdlib] Use array copy in String.toCharArray()
...
And don't use copy during internal non-mutating algorithms
2021-10-23 01:26:11 +03:00
Svyatoslav Kuzmich
0f66f85cf9
[Wasm] Support main function
2021-10-15 13:58:55 +03:00
Igor Laevsky
cb5bef1535
[Wasm] Remove unnecessary testHelpers and add assertions from stdlib
2021-10-14 17:24:06 +03:00
Igor Laevsky
bede039c08
[Wasm] Add compiler support for the kotlin.test library
2021-10-14 17:24:05 +03:00
Igor Laevsky
7943298240
[Wasm] Add sorting function to the stdlib
2021-10-14 17:24:04 +03:00
Igor Laevsky
049e48e780
[Wasm] Keep error message for the IAE exception
2021-10-14 17:24:03 +03:00
Igor Laevsky
14eee7c539
[Wasm] Add kotlin-test-wasm library
2021-10-14 17:24:02 +03:00
Svyatoslav Kuzmich
3bce0cc055
[Wasm] Support coroutines
...
- Reuse JS IR Suspend function lowering
- Fix types
- Disable reinterpretCast-based optimization for inline
classes
- Add basic support to Wasm stdlib
- Explicitly transform suspend functions into regular functions
with continuations
- Clean suspend function handling from JS IR codegen
2021-10-12 08:42:01 +03:00
Svyatoslav Kuzmich
9ef899ef10
[Wasm] Reuse Callable reference and SAM lowerings from JS
2021-10-08 07:24:41 +03:00
Svyatoslav Kuzmich
1ed2748334
[Wasm] Generate [K][Suspend]FunctionN on demand and support big arity
2021-10-08 07:24:41 +03:00
Svyatoslav Kuzmich
fa3e75463e
[Wasm] Support throwIAE and throwNoBranchMatchedException
...
Add a couple of test stubs
Unmute tests
2021-10-02 06:14:36 +00:00
Svyatoslav Kuzmich
ab9a23cbfa
[Wasm][Stdlib] Reuse K/N collections and StringBuilder
2021-10-01 17:18:49 +03:00
Abduqodiri Qurbonzoda
f8bcba0b76
Align JS String.equals/compareTo(ignoreCase) behavior with JVM #KT-48999
2021-09-30 15:35:50 +00:00
Svyatoslav Kuzmich
dd45714137
[Wasm] Add property reference stdlib part
2021-09-27 17:08:55 +03:00
Svyatoslav Kuzmich
5c05ff48ff
[Wasm] Copy property reference lowering from K/N
2021-09-27 17:07:39 +03:00
Ilya Gorbunov
7666377565
Control Duration init block assertions on JVM with -ea option
...
On other platforms enable them unconditionally
2021-09-24 16:17:54 +00:00
Ilya Gorbunov
96611de344
Stabilize Duration, DurationUnit and related top-level functions KT-46784
...
Co-authored-by: Abduqodiri Qurbonzoda <abduqodiri.qurbonzoda@jetbrains.com >
2021-09-24 16:17:53 +00:00
Abduqodiri Qurbonzoda
261d0c2783
Promote collection builders to stable #KT-47421
2021-09-21 11:25:28 +00:00
Igor Laevsky
15668e2266
[WASM] Lower Unit to Void in order to mark statements with no result
2021-09-16 20:24:44 +03:00
Abduqodiri Qurbonzoda
3ddc29363a
Remove deprecated Common synchronized and deprecate it in JS #KT-46101
2021-09-16 19:38:37 +03:00
Abduqodiri Qurbonzoda
d9f8ce899a
Promote rotateLeft and rotateRight to stable
2021-09-16 19:27:21 +03:00
Svyatoslav Kuzmich
de7fa8c778
[Wasm][Stdlib] Add kotlin.js.JsExport annotation
2021-09-16 14:20:34 +03:00
Igor Laevsky
6ca965af6f
WASM: Generate throw instruction instead of wasmThrow call
2021-09-08 19:56:33 +03:00