mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 12:49:19 +00:00
LibJS: Allow using local variable for catch parameters
Local variables are faster to access and if all catch parameters are locals we can skip lexical environment allocation.
This commit is contained in:
parent
0f14c70252
commit
7932091e02
Notes:
github-actions[bot]
2025-04-22 19:58:29 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: 7932091e02
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4421
Reviewed-by: https://github.com/gmta
3 changed files with 49 additions and 28 deletions
|
@ -320,7 +320,6 @@ private:
|
|||
bool initiated_by_eval { false };
|
||||
bool in_eval_function_context { false }; // This controls if we allow new.target or not. Note that eval("return") is not allowed, so we have to have a separate state variable for eval.
|
||||
bool in_formal_parameter_context { false };
|
||||
bool in_catch_parameter_context { false };
|
||||
bool in_generator_function_context { false };
|
||||
bool await_expression_is_valid { false };
|
||||
bool in_arrow_function_context { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue