Linus Groh
cbc4cf057d
LibJS: Improve an alias name in ToSecondsStringPrecision
...
This is an editorial change in the Temporal spec.
See: b75bd9e
2022-06-15 17:49:20 +01:00
Linus Groh
4494be8cf2
LibJS: Inline call to AddISODate in ZonedDateTime.prototype.hoursInDay
...
This is an editorial change in the Temporal spec.
See: f034239
2022-06-15 17:49:20 +01:00
Linus Groh
810e9e32c9
LibJS: Remove RegulateISODate after BalanceISODate in AddISODate
...
This is an editorial change in the Temporal spec.
See: 32b22b1
2022-06-15 17:49:20 +01:00
Linus Groh
e96df3b7a7
LibJS: Leverage PrepareTemporalFields in ToTemporalTimeRecord
...
This is an editorial change in the Temporal spec.
See: b5ba981
2022-06-15 17:49:20 +01:00
Linus Groh
6cc69bbd8e
LibJS: Rename ToPartialDuration to ToTemporalPartialDurationRecord
...
This is an editorial change in the Temporal spec.
See: 0509d41
2022-06-15 17:49:20 +01:00
Linus Groh
6982e53113
LibJS: Leverage ToPartialDuration in ToTemporalDurationRecord
...
This is an editorial change in the Temporal spec.
See: c3efde0
2022-06-15 17:49:20 +01:00
Linus Groh
9bcd88828f
LibJS: Fold ToPartialTime into ToTemporalTimeRecord
...
This is an editorial change in the Temporal spec.
See: 58e476d
2022-06-15 17:49:20 +01:00
Linus Groh
3e6561c75f
LibJS: Fold PreparePartialTemporalFields into PrepareTemporalFields
...
This is an editorial change in the Temporal spec.
See: 6ed1835
2022-06-15 17:49:20 +01:00
Linus Groh
631f270ac1
LibJS: Add missing conversion to integer values in Calendar AOs
...
This is an editorial change in the Temporal spec.
See: bfeb523
2022-06-15 17:49:20 +01:00
Linus Groh
03f48056d5
LibJS: Mark various uses of CreateTemporalTime as infallible
...
These are editorial changes in the Temporal spec.
See:
- dd35d5e
- 1ec6673
- 8c04e3b
- df7a802
- 5fc71ae
- ca305c6
2022-06-15 17:49:20 +01:00
Obinna Ikeh
3d99e83a86
LibJS: Update order of parameters in our is_less_than implementation
...
This change updates the parameter order of the is_less_than function
signature and calls to match accordingly with the spec
(https://tc39.es/ecma262/#sec-islessthan )
2022-06-13 17:37:11 -07:00
Linus Groh
698062b831
LibJS: Implement Array.prototype.with()
2022-06-13 20:26:54 +01:00
Linus Groh
ae81793f20
LibJS: Implement Array.prototype.toSpliced()
2022-06-13 20:26:54 +01:00
Linus Groh
ce17c868c0
LibJS: Implement Array.prototype.toSorted()
2022-06-13 20:26:54 +01:00
Linus Groh
e4370b7d82
LibJS: Implement Array.prototype.toReversed()
2022-06-13 20:26:54 +01:00
Linus Groh
e2a5a27302
LibJS: Implement the SortIndexedProperties AO
...
Also use it in array_merge_sort() instead of inlining the algorithm.
2022-06-13 20:26:54 +01:00
Linus Groh
5ddf0b0c99
LibJS: Implement the CompareArrayElements AO
2022-06-13 20:26:54 +01:00
Linus Groh
aa5d5bf1c8
LibJS: Remove redundant VM& parameter from array_merge_sort()
...
This is covered by GlobalObject& just fine.
2022-06-13 20:26:54 +01:00
Linus Groh
105c516a78
LibJS: Make array_merge_sort() public
2022-06-13 20:26:54 +01:00
Linus Groh
a4d0a6e1c1
LibJS: Update Array.prototype.group{,ToMap} spec URLs
...
This is an editorial change in the Array Grouping spec.
See: c51cac5
2022-06-13 20:15:56 +01:00
Linus Groh
013e2df858
LibJS: Rename Array.prototype.groupBy{,ToMap} => group{,ToMap}
...
This is a normative change in the Array Grouping spec.
See: 0cf4077
2022-06-13 20:05:24 +01:00
Matthias Zimmerman
c10d48b72c
AK/ByteBuffer+Everywhere: Handle errors in ByteBuffer::slice()
2022-06-13 15:38:51 +01:00
Luke Wilde
125a71d36d
LibJS/Bytecode: Define named functions as a variable inside their scope
...
This allows you to recurse into a named function that is stored in a
variable. For example, this would previously print "wrong" instead of
"right":
```js
function g() { console.log("wrong") }
f = function g(i) { if (i !== 1) g(1); else console.log("right"); }
f()
```
2022-06-13 07:13:03 +04:30
Luke Wilde
9ad807d08b
LibJS/Bytecode: Pass contains_direct_call_to_eval into ESFO::create
...
Previously it would pass in `is_arrow_function` as
`contains_direct_call_to_eval`, which broke strict mode propagation in
arrow functions. This makes test-js work without falling apart because
`this` is mysteriously undefined because of the use of arrow functions
inside classes, which are strict mode by default.
2022-06-13 07:13:03 +04:30
Luke Wilde
77f88d00e0
LibJS/Bytecode: Make return;
return undefined
...
Previously it would return whatever was in the accumulator.
2022-06-13 07:13:03 +04:30
Luke Wilde
482a827346
LibJS/Bytecode: Make typeof return "undefined" on unresolvable IDs
...
Previously it would throw instead of returning "undefined" for
`typeof Identifier` if Identifier does not exist.
2022-06-13 07:13:03 +04:30
Luke Wilde
c0fadfb9b7
LibJS/Bytecode: Implement break/continue labels
...
This is done by keeping track of all the labels that apply to a given
break/continue scope alongside their bytecode target. When a
break/continue with a label is generated, we scan from the most inner
scope to the most outer scope looking for the label, performing any
necessary unwinds on the way. Once the label is found, it is then
jumped to.
2022-06-13 07:13:03 +04:30
Linus Groh
4c77575ec5
LibJS: Simplify Temporal unit AOs
...
This is an editorial change in the Temporal spec.
See: 1b3d018
2022-06-10 12:39:11 +02:00
Linus Groh
b9beb2b120
LibJS: Remove unnecessary ToLimitedTemporalDuration AO
...
This is an editorial change in the Temporal spec.
See: c6571f4
2022-06-10 12:39:11 +02:00
Linus Groh
237f537b5c
LibJS: Align DifferenceTemporalInstant with similar AOs
...
This is an editorial change in the Temporal spec.
See: cf9118b
2022-06-10 12:39:11 +02:00
Linus Groh
3bb94dd62e
LibJS: Refactor Temporal parse AOs
...
This is an editorial change in the Temporal spec.
See: 7fe29eb
2022-06-10 12:39:11 +02:00
Linus Groh
86e22abd76
LibJS: Rename DefaultMergeFields to DefaultMergeCalendarFields
...
This is an editorial change in the Temporal spec.
See: 0ee80b2
2022-06-10 12:39:11 +02:00
Linus Groh
125530c71d
LibJS: Mark a call of CreateTemporalDate as infallible
...
This is an editorial change in the Temporal spec.
See: c403d3f
2022-06-10 12:39:11 +02:00
stelar7
771e3b9868
LibJS: Stub out String.prototype.normalize
2022-06-02 23:04:27 +01:00
Linus Groh
9400b76d79
LibJS: Remove assertions replaced with structured headers
...
This is an editorial change in the Temporal spec.
See: 74fd5e8
2022-05-25 00:25:23 +01:00
Linus Groh
c3f1d8f5ba
LibJS: Correct section IDs of Temporal .prototype property clauses
...
This is an editorial change in the Temporal spec.
See: e4eb181
2022-05-25 00:25:23 +01:00
Linus Groh
ae1fdf299d
LibJS: Use the rounding abstract operations from Intl.NumberFormat V3
...
This is an editorial change in the Temporal spec.
See: 75279e5
Co-Authored-By: Idan Horowitz <idan.horowitz@gmail.com>
2022-05-25 00:25:23 +01:00
Linus Groh
93a20b3bfb
LibJS: Use default argument of CalendarDateFromFields
...
This is an editorial change in the Temporal spec.
See: 7a4a518
2022-05-25 00:25:23 +01:00
Linus Groh
cf1ea18b7f
LibJS: Align DifferenceTemporalPlainTime with other Difference* AOs
...
This is an editorial change in the Temporal spec.
See: 70f739d
2022-05-25 00:25:23 +01:00
Linus Groh
89d4094709
LibJS: Mark concrete method calls of Environment Records with ?/!
...
This is an editorial change in the ECMA-262 spec.
See: 7ae3ecf
2022-05-25 00:25:23 +01:00
Linus Groh
74695ce76e
LibJS: Mark two Get operations in ToTemporalZonedDateTime infallible
...
This is an editorial change in the Temporal spec.
See: fed9f16
2022-05-17 21:24:50 +01:00
Linus Groh
a5c41aa905
LibJS: Use required fields argument in ISOYearMonthFromFields
...
This is an editorial change in the Temporal spec.
See: ff02f87
2022-05-17 21:16:56 +01:00
Linus Groh
0946f82c8c
LibJS: Combine TemporalTimeZoneIdentifier and TimeZoneBracketedName
...
This is an editorial change in the Temporal spec.
See: 6db76f4
2022-05-17 21:14:01 +01:00
Luke Wilde
2b764b3594
LibJS: Remove faulty assertion in BalanceDurationRelative
...
This is an editorial change in the Temporal spec.
See: 66f7464
2022-05-16 20:48:41 +01:00
Linus Groh
d2c1dd5454
LibJS: Introduce ISO Date Records
...
This is an editorial change in the Temporal spec.
See: d264341
2022-05-16 20:46:46 +01:00
Linus Groh
0558eb6d2f
LibJS: Swap until/since arguments to DifferenceTemporalZonedDateTime
...
This is an editorial change in the Temporal spec.
See: b911bc9
2022-05-16 20:35:13 +01:00
Linus Groh
6d7970a23c
LibJS: Remove unnecessary CalendarDate production
...
This is an editorial change in the Temporal spec.
See: 48744ea
2022-05-16 20:33:22 +01:00
Linus Groh
03017be5bd
LibJS: Remove redundant TemporalRelativeToString production
...
This is an editorial change in the Temporal spec.
See: f85f953
2022-05-16 20:29:32 +01:00
Linus Groh
51e01b5a80
LibJS: Remove redundant TemporalDateString production
...
This is an editorial change in the Temporal spec.
See: 41a8a5c
2022-05-16 20:28:26 +01:00
Linus Groh
33f53041e7
LibJS: Replace "enclosed by" with "contained within" in spec comments
...
This is an editorial change in the Temporal spec.
See: cb10d3f
2022-05-16 20:17:23 +01:00