Commit Graph

16 Commits

Author SHA1 Message Date
Zia
f058e2a5f3 new string allocator 2024-03-14 01:19:41 +03:30
Charlie Gordon
06c100c9bf Prevent UB on memcpy and floating point conversions
- add `memcpy_no_ub` that accepts null pointers for 0 count
- prevent 0 length allocation in `js_worker_postMessage`
- use safer test for `int` value in `JS_NewFloat64`,
  `JS_ToArrayLengthFree` and `js_typed_array_indexOf`
2024-03-03 14:05:40 +01:00
Tyler Rockwood
b91a2aec67 Add C API function JS_GetClassID()
If you want to extend a built-in class you need it's class ID and there
is no robust way to get that without this accessor.

* add JS_INVALID_CLASS_ID constant for invalid class ID.

Signed-off-by: Tyler Rockwood <rockwood@redpanda.com>
2024-02-21 15:33:37 +01:00
Charlie Gordon
37bd4ae62d Strip trailing spaces 2024-02-10 16:19:17 +01:00
Fabrice Bellard
c6cc6a9a5e export JS_GetModuleNamespace (github issue #34) 2024-01-27 13:27:32 +01:00
Fabrice Bellard
e44b793e38 allow 'await' in the REPL and added os.sleepAsync() 2024-01-02 16:09:30 +01:00
Fabrice Bellard
6e4931c4ad top-level-await support - follow the spec in the implementation of the module linking and evaluation to avoid errors with cycling module dependencies 2023-12-27 17:10:47 +01:00
Fabrice Bellard
58f374ef42 reworked set property and fixed corner cases of typed array set property 2023-12-09 12:30:31 +01:00
bellard
b5e62895c6 2021-03-27 release 2021-03-27 11:17:31 +01:00
bellard
b1f67dfc1a 2020-11-08 release 2020-11-08 14:30:56 +01:00
bellard
7c312df422 2020-09-06 release 2020-09-06 19:10:15 +02:00
bellard
8900766099 2020-07-05 release 2020-09-06 19:07:30 +02:00
bellard
1722758717 2020-04-12 release 2020-09-06 19:04:20 +02:00
bellard
383e2b06c8 2020-03-16 release 2020-09-06 19:02:03 +02:00
bellard
0e8fffd4de 2020-01-19 release 2020-09-06 18:57:11 +02:00
bellard
91459fb672 2020-01-05 release 2020-09-06 18:53:08 +02:00