mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:37:37 +00:00
LibJS: Convert create_data_property_or_throw() to ThrowCompletionOr
This commit is contained in:
parent
bb2499cd7a
commit
364dd42fc8
30 changed files with 148 additions and 167 deletions
|
@ -694,8 +694,7 @@ Object* create_unmapped_arguments_object(GlobalObject& global_object, Span<Value
|
|||
auto value = arguments[index];
|
||||
|
||||
// b. Perform ! CreateDataPropertyOrThrow(obj, ! ToString(𝔽(index)), val).
|
||||
object->create_data_property_or_throw(index, value);
|
||||
VERIFY(!vm.exception());
|
||||
MUST(object->create_data_property_or_throw(index, value));
|
||||
|
||||
// c. Set index to index + 1.
|
||||
}
|
||||
|
@ -742,8 +741,7 @@ Object* create_mapped_arguments_object(GlobalObject& global_object, FunctionObje
|
|||
auto value = arguments[index];
|
||||
|
||||
// b. Perform ! CreateDataPropertyOrThrow(obj, ! ToString(𝔽(index)), val).
|
||||
object->create_data_property_or_throw(index, value);
|
||||
VERIFY(!vm.exception());
|
||||
MUST(object->create_data_property_or_throw(index, value));
|
||||
|
||||
// c. Set index to index + 1.
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue