mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-02 23:56:06 +00:00
LibJS: Convert create_mutable_binding() to ThrowCompletionOr
Also add spec step comments to it while we're here.
This commit is contained in:
parent
fbb176c926
commit
4baf3a91e8
Notes:
sideshowbarker
2024-07-18 02:52:32 +09:00
Author: https://github.com/linusg
Commit: 4baf3a91e8
Pull-request: https://github.com/SerenityOS/serenity/pull/10413
Reviewed-by: https://github.com/IdanHo ✅
10 changed files with 43 additions and 39 deletions
|
@ -34,7 +34,7 @@ public:
|
|||
virtual Object* with_base_object() const { return nullptr; }
|
||||
|
||||
virtual ThrowCompletionOr<bool> has_binding([[maybe_unused]] FlyString const& name, [[maybe_unused]] Optional<size_t>* out_index = nullptr) const { return false; }
|
||||
virtual void create_mutable_binding(GlobalObject&, [[maybe_unused]] FlyString const& name, [[maybe_unused]] bool can_be_deleted) { }
|
||||
virtual ThrowCompletionOr<void> create_mutable_binding(GlobalObject&, [[maybe_unused]] FlyString const& name, [[maybe_unused]] bool can_be_deleted) { return {}; }
|
||||
virtual void create_immutable_binding(GlobalObject&, [[maybe_unused]] FlyString const& name, [[maybe_unused]] bool strict) { }
|
||||
virtual void initialize_binding(GlobalObject&, [[maybe_unused]] FlyString const& name, Value) { }
|
||||
virtual void set_mutable_binding(GlobalObject&, [[maybe_unused]] FlyString const& name, Value, [[maybe_unused]] bool strict) { }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue