Idan Horowitz
5af8f72d54
LibJS: Convert PromiseConstructor functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
81bdb20c61
LibJS: Convert the PromiseResolve AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
0d602c5ec5
LibJS: Convert the NewPromiseCapability AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
2b87f77578
LibJS: Convert DatePrototype functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
ba39a54bb8
LibJS: Convert DateConstructor functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
306c25f3c2
LibJS: Convert the NumberToBigInt AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
f7bafea661
LibJS: Convert TypedArrayConstructor functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
92b25cacd1
LibJS: Convert TypedArrayPrototype functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
94be1f772a
LibJS: Convert typed_array_merge_sort to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
86aa8a14ea
LibJS: Convert the TypedArraySpeciesCreate AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
18c2d537c7
LibJS: Convert StringPrototype functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
38c4693c70
LibJS: Convert the CreateHTML AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
0948bd8c1e
LibJS: Convert the PadString AO to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
70a35f9600
LibJS: Convert resolve_best_locale to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Idan Horowitz
28e1e03234
LibJS: Convert StringConstructor functions to ThrowCompletionOr
2021-10-23 18:01:51 +02:00
Linus Groh
dd2655c1fb
LibJS: Update Annex B String.prototype extension spec section numbers
2021-10-23 11:38:13 +02:00
Linus Groh
d655a0a42e
LibJS: Add "at" to Array.prototype[@@unscopables]
2021-10-23 11:38:13 +02:00
Linus Groh
534fd41fa3
LibJS: Use ECMA-262 spec URLs for .at() (relative indexing, now stage 4)
2021-10-23 11:38:13 +02:00
Linus Groh
5ff7d7945d
LibJS: Use ECMA-262 spec URL for Object.hasOwn() (now stage 4)
2021-10-23 11:38:13 +02:00
Linus Groh
60ee542612
LibJS: Mark GetEpochFromISOParts as infallible
...
This is an editorial change in the Temporal spec.
See: 66ea81b
2021-10-23 01:05:50 +01:00
Idan Horowitz
0f5cfe975f
LibJS: Convert ArrayPrototype functions to ThrowCompletionsOr
2021-10-23 02:49:41 +03:00
Idan Horowitz
36446c0bd5
LibJS: Convert the FlattenIntoArray AO to ThrowCompletionOr
2021-10-23 02:49:41 +03:00
Idan Horowitz
953265805e
LibJS: Convert array_merge_sort to ThrowCompletionOr
2021-10-23 02:49:41 +03:00
Idan Horowitz
ad318ec123
LibJS: Convert the ArraySpeciesCreate AO to ThrowCompletionOr
2021-10-23 02:49:41 +03:00
Idan Horowitz
36aef8ee95
LibJS: Convert ArrayConstructor functions to ThrowCompletionOr
2021-10-23 02:49:41 +03:00
Idan Horowitz
e26d9f419b
LibJS: Remove vm.construct and it's usages
2021-10-23 02:49:41 +03:00
Linus Groh
66770de264
LibJS: Convert Intl.NumberFormat functions to ThrowCompletionOr
2021-10-22 23:20:18 +01:00
Linus Groh
351f0b70bd
LibJS: Convert Intl.Locale functions to ThrowCompletionOr
2021-10-22 23:20:18 +01:00
Linus Groh
9fb1d7e18b
LibJS: Convert Intl.ListFormat functions to ThrowCompletionOr
2021-10-22 23:20:18 +01:00
Linus Groh
15eadcf023
LibJS: Convert Intl.DisplayNames functions to ThrowCompletionOr
2021-10-22 23:20:18 +01:00
Linus Groh
68df9e4dfb
LibJS: Convert Intl.getCanonicalLocales() function to ThrowCompletionOr
2021-10-22 23:20:18 +01:00
Idan Horowitz
db5df26841
LibJS: Convert Array AOs to ThrowCompletionOr
2021-10-22 15:07:04 +03:00
Idan Horowitz
3426285738
LibJS: Convert Locale AOs to ThrowCompletionOr
2021-10-22 15:07:04 +03:00
Linus Groh
9143d37907
LibJS: Convert Temporal.ZonedDateTime functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
7085458a23
LibJS: Convert Temporal.TimeZone functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
15f52c5f8e
LibJS: Convert Temporal.PlainYearMonth functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
e4e04528af
LibJS: Convert Temporal.PlainTime functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
c8e359c25e
LibJS: Convert Temporal.PlainMonthDay functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
c043b818ad
LibJS: Convert Temporal.PlainDateTime functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
2093128b24
LibJS: Convert Temporal.PlainDate functions to ThrowCompletionOr
2021-10-21 22:31:31 +01:00
Linus Groh
df67f4978e
LibJS: Convert Temporal.Now functions to ThrowCompletionOr
2021-10-21 22:31:09 +01:00
Linus Groh
149231d47d
LibJS: Convert Temporal.Instant functions to ThrowCompletionOr
2021-10-21 22:31:09 +01:00
Linus Groh
5e9e3f9dc8
LibJS: Convert Temporal.Duration functions to ThrowCompletionOr
2021-10-21 22:31:09 +01:00
Linus Groh
2d2ba4eec6
LibJS: Convert Temporal.Calendar functions to ThrowCompletionOr
2021-10-21 22:31:09 +01:00
Timothy Flynn
4e4db65e26
LibJS: Remove now-redundant TemporaryClearException from Promise methods
...
IteratorClose now handles exceptions itself before invoking VM::call(),
so outside callers doubling that work isn't helpful.
2021-10-21 14:57:43 +01:00
Timothy Flynn
f8e46ec296
LibJS: Convert all four PerformPromise* AOs to ThrowCompletionOr
2021-10-21 14:46:14 +01:00
Timothy Flynn
4fb948d8e7
LibJS: Convert IfAbruptRejectPromise AO to a GNU statement expression
...
GNU statement expressions fit the definition of IfAbruptRejectPromise
rather nicely, where we need to reject the failed promise (and return
the failed promise itself) on failure, and otherwise store a value on
success.
2021-10-21 14:46:14 +01:00
Timothy Flynn
9064491a47
LibJS: Convert GetPromiseResolve AO to ThrowCompletionOr
...
This is a bit ugly because, rather than simply wrapping the invocation
to GetPromiseResolve with TRY(), we have to invoke the promise's reject
method with any error. But this will be a bit cleaner in a subsequent
commit to change how IfAbruptRejectPromise is invoked.
2021-10-21 14:46:14 +01:00
Linus Groh
5832de62fe
LibJS: Convert NativeFunction::{call,construct}() to ThrowCompletionOr
...
Both at the same time because many of them call construct() in call()
and I'm not keen on adding a bunch of temporary plumbing to turn
exceptions into throw completions.
Also changes the return value of construct() to Object* instead of Value
as it always needs to return an object; allowing an arbitrary Value is a
massive foot gun.
2021-10-21 09:02:23 +01:00
Linus Groh
0881f8160f
LibJS: Use implicit ThrowCompletionOr<T> constructor where possible
...
Luckily this is not very widespread yet as most of it would happen in
the various JS functions instead of AOs.
2021-10-21 09:02:23 +01:00