mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-07 00:29:15 +00:00
LibWeb: Implement StructuredSerialize for BigIntObject and Symbol
This commit is contained in:
parent
f3cf7496a1
commit
b3bd232a5e
Notes:
sideshowbarker
2024-07-16 22:26:05 +09:00
Author: https://github.com/ADKaster
Commit: b3bd232a5e
Pull-request: https://github.com/SerenityOS/serenity/pull/20703
3 changed files with 29 additions and 2 deletions
|
@ -6,6 +6,15 @@
|
|||
println(structuredClone(new Number(123)));
|
||||
println(structuredClone(new Number(123.456)));
|
||||
println(structuredClone(new String("This is a String object")));
|
||||
println(structuredClone(BigInt("0x1fffffffffffff")));
|
||||
println(structuredClone(Date.UTC(2023, 7, 23)));
|
||||
|
||||
try {
|
||||
structuredClone(Symbol("foo"));
|
||||
println("FAILED")
|
||||
}
|
||||
catch(e) {
|
||||
println("ERROR: " + e.name + ": " + e.message)
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue