mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 03:57:44 +00:00
LibJS+LibWeb: Wrap raw JS::Cell*/& fields in GCPtr/NonnullGCPtr
This commit is contained in:
parent
1df3652e27
commit
7c0c1c8f49
214 changed files with 825 additions and 827 deletions
|
@ -35,8 +35,8 @@ public:
|
|||
}
|
||||
|
||||
Optional<Value> value {};
|
||||
Optional<FunctionObject*> get {};
|
||||
Optional<FunctionObject*> set {};
|
||||
Optional<GCPtr<FunctionObject>> get {};
|
||||
Optional<GCPtr<FunctionObject>> set {};
|
||||
Optional<bool> writable {};
|
||||
Optional<bool> enumerable {};
|
||||
Optional<bool> configurable {};
|
||||
|
@ -54,9 +54,9 @@ struct Formatter<JS::PropertyDescriptor> : Formatter<StringView> {
|
|||
if (property_descriptor.value.has_value())
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Value]]: {}", TRY(property_descriptor.value->to_string_without_side_effects())))));
|
||||
if (property_descriptor.get.has_value())
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Get]]: JS::Function* @ {:p}", *property_descriptor.get))));
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Get]]: JS::Function* @ {:p}", property_descriptor.get->ptr()))));
|
||||
if (property_descriptor.set.has_value())
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Set]]: JS::Function* @ {:p}", *property_descriptor.set))));
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Set]]: JS::Function* @ {:p}", property_descriptor.set->ptr()))));
|
||||
if (property_descriptor.writable.has_value())
|
||||
TRY(parts.try_append(TRY(String::formatted("[[Writable]]: {}", *property_descriptor.writable))));
|
||||
if (property_descriptor.enumerable.has_value())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue