Remove duplicated parameter-check methods

Signed-off-by: Hyukwoo Park <hyukwoo.park@jbnu.ac.kr>
This commit is contained in:
Hyukwoo Park 2026-03-03 10:24:32 +09:00 committed by Patrick Kim
commit 989e6922b6
4 changed files with 5 additions and 15 deletions

View file

@ -186,7 +186,7 @@ InterpretedCodeBlock* ScriptParser::generateCodeBlockTreeFromASTWalker(Context*
bool needToCaptureArguments = false;
InterpretedCodeBlock* argumentsObjectHolder = codeBlock;
while (argumentsObjectHolder && !argumentsObjectHolder->isGlobalCodeBlock()) {
if (UNLIKELY(argumentsObjectHolder->hasParameterName(arguments))) {
if (UNLIKELY(argumentsObjectHolder->isParameterName(arguments))) {
// no need to create arguments object since it has a parameter of which name is `arguments`
break;
}