Files
ladybird/Userland
mattco98 95abcc3722 LibJS: Implement correct object property ordering
This commit introduces a way to get an object's own properties in the
correct order. The "correct order" for JS object properties is first all
array-like index properties (numeric keys) sorted by insertion order,
followed by all string properties sorted by insertion order.

Objects also now print correctly in the repl! Before this commit:

courage ~/js-tests $ js
> ({ foo: 1, bar: 2, baz: 3 })
{ bar: 2, foo: 1, baz: 3 }

After:

courage ~/js-tests $ js
> ({ foo: 1, bar: 2, baz: 3 })
{ foo: 1, bar: 2, baz: 3 }
2020-04-29 18:47:03 +02:00
..
2020-04-26 12:54:22 +02:00
2020-02-16 09:41:56 +01:00
2020-02-18 13:29:54 +01:00
2020-02-16 09:51:49 +01:00
2020-02-18 11:35:47 +01:00
2020-03-20 14:41:23 +01:00
2020-03-06 22:46:17 +01:00
2020-02-20 13:20:34 +01:00
2020-03-04 18:06:17 +01:00
2020-02-18 11:35:47 +01:00
2020-02-18 13:29:54 +01:00
2020-04-06 11:09:01 +02:00
2020-04-16 11:17:33 +02:00
2020-04-21 16:19:18 +02:00
2020-02-11 12:16:07 +01:00
2020-02-18 13:29:54 +01:00
2020-04-25 12:09:46 +02:00
2020-04-16 11:17:33 +02:00
2020-01-27 21:38:36 +01:00
2020-04-19 11:14:26 +02:00
2020-02-18 13:29:54 +01:00
2020-02-18 11:35:47 +01:00
2020-04-13 00:53:22 +02:00
2020-02-18 13:29:54 +01:00
2020-02-18 13:29:54 +01:00
2020-02-18 11:35:47 +01:00
2020-02-18 11:35:47 +01:00
2020-02-18 11:35:47 +01:00
2020-02-18 11:35:47 +01:00