mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 19:07:36 +00:00
LibJS: Improve ResolveBinding + add GetIdentifierReference
ResolveBinding now matches the spec, while the non-conforming parts are moved to GetIdentifierReference. Implementing this properly requires variable bindings.
This commit is contained in:
parent
4b87dd5c5c
commit
fd43d1e205
3 changed files with 36 additions and 9 deletions
|
@ -204,7 +204,8 @@ public:
|
|||
void assign(const FlyString& target, Value, GlobalObject&, bool first_assignment = false, Environment* specific_scope = nullptr);
|
||||
void assign(const NonnullRefPtr<BindingPattern>& target, Value, GlobalObject&, bool first_assignment = false, Environment* specific_scope = nullptr);
|
||||
|
||||
Reference resolve_binding(GlobalObject&, FlyString const&, Environment* = nullptr);
|
||||
Reference resolve_binding(FlyString const&, Environment* = nullptr);
|
||||
Reference get_identifier_reference(Environment*, FlyString const&, bool strict);
|
||||
|
||||
template<typename T, typename... Args>
|
||||
void throw_exception(GlobalObject& global_object, Args&&... args)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue