mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-26 03:09:08 +00:00
LibJS: Move "strict mode" state to the call stack
Each call frame now knows whether it's executing in strict mode. It's no longer necessary to access the scope stack to find this mode.
This commit is contained in:
@@ -57,7 +57,7 @@ BoundFunction* Function::bind(Value bound_this_value, Vector<Value> arguments)
|
||||
switch (bound_this_value.type()) {
|
||||
case Value::Type::Undefined:
|
||||
case Value::Type::Null:
|
||||
if (interpreter().in_strict_mode())
|
||||
if (vm().in_strict_mode())
|
||||
return bound_this_value;
|
||||
return &global_object();
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user