mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-11 10:41:30 +00:00
LibJS: Allow JS::Value to store a non-object Cell
This will allow us to refer to non-object Cells more readily in bytecode and opens up for some nice optimizations.
This commit is contained in:
parent
f0abf5a43b
commit
1d88c4529c
Notes:
github-actions[bot]
2025-03-22 22:00:41 +00:00
Author: https://github.com/awesomekling
Commit: 1d88c4529c
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4051
1 changed files with 5 additions and 0 deletions
|
@ -214,6 +214,11 @@ public:
|
|||
{
|
||||
}
|
||||
|
||||
Value(Cell const* cell)
|
||||
: Value(GC::IS_CELL_BIT << GC::TAG_SHIFT, reinterpret_cast<void const*>(cell))
|
||||
{
|
||||
}
|
||||
|
||||
Value(Object const* object)
|
||||
: Value(OBJECT_TAG << GC::TAG_SHIFT, reinterpret_cast<void const*>(object))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue