From cdee6cd010760a99f9781739a23d4dd132a1471a Mon Sep 17 00:00:00 2001 From: Ronald Brill Date: Fri, 4 Oct 2024 19:15:36 +0200 Subject: [PATCH] remove unused var 'declaredAsVar' from class InterpreterData --- rhino/src/main/java/org/mozilla/javascript/CodeGenerator.java | 3 --- .../src/main/java/org/mozilla/javascript/InterpreterData.java | 3 --- 2 files changed, 6 deletions(-) diff --git a/rhino/src/main/java/org/mozilla/javascript/CodeGenerator.java b/rhino/src/main/java/org/mozilla/javascript/CodeGenerator.java index f01832ead3..1ece422f8d 100644 --- a/rhino/src/main/java/org/mozilla/javascript/CodeGenerator.java +++ b/rhino/src/main/java/org/mozilla/javascript/CodeGenerator.java @@ -20,7 +20,6 @@ import org.mozilla.javascript.ast.Scope; import org.mozilla.javascript.ast.ScriptNode; import org.mozilla.javascript.ast.TemplateCharacters; -import org.mozilla.javascript.ast.VariableInitializer; /** Generates bytecode for the Interpreter. */ class CodeGenerator extends Icode { @@ -119,8 +118,6 @@ private void generateFunctionICode() { itsData.isES6Generator = true; } - itsData.declaredAsVar = (theFunction.getParent() instanceof VariableInitializer); - generateICodeFromTree(theFunction.getLastChild()); } diff --git a/rhino/src/main/java/org/mozilla/javascript/InterpreterData.java b/rhino/src/main/java/org/mozilla/javascript/InterpreterData.java index 45ff68eb06..cab50a0067 100644 --- a/rhino/src/main/java/org/mozilla/javascript/InterpreterData.java +++ b/rhino/src/main/java/org/mozilla/javascript/InterpreterData.java @@ -95,9 +95,6 @@ private void init() { private int icodeHashCode = 0; - /** true if the function has been declared like "var foo = function() {...}" */ - boolean declaredAsVar; - /** true if the function has been declared like "!function() {}". */ boolean declaredAsFunctionExpression;