1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 07:57:47 +00:00

LibJS: Make Heap a friend of everyone who uses JS_CELL

This will allow Heap to invoke non-public constructors when allocating
new cells.
This commit is contained in:
Andreas Kling 2022-08-28 22:13:05 +02:00
parent 49fd92d92a
commit d54ba587f3

View file

@ -20,7 +20,8 @@ public: \
virtual StringView class_name() const override \ virtual StringView class_name() const override \
{ \ { \
return #class_##sv; \ return #class_##sv; \
} } \
friend class JS::Heap;
class Cell { class Cell {
AK_MAKE_NONCOPYABLE(Cell); AK_MAKE_NONCOPYABLE(Cell);