From: axelcl Date: Thu, 13 Oct 2005 20:11:59 +0000 (+0000) Subject: Avoid "uninitialized variable" message after new keyword X-Git-Url: http://git.phpeclipse.com Avoid "uninitialized variable" message after new keyword --- diff --git a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/parser/Parser.java b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/parser/Parser.java index a79cbef..4dcd0f8 100644 --- a/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/parser/Parser.java +++ b/net.sourceforge.phpeclipse/src/net/sourceforge/phpdt/internal/compiler/parser/Parser.java @@ -2787,7 +2787,7 @@ public class Parser implements ITerminalSymbols, CompilerModifiers, ParserBasicI if (Scanner.TRACE) { System.out.println("TRACE: dynamic_class_name_reference()"); } - base_variable(); + base_variable(true); if (token == TokenNameMINUS_GREATER) { getNextToken(); object_property(); @@ -3103,7 +3103,7 @@ public class Parser implements ITerminalSymbols, CompilerModifiers, ParserBasicI return function_call(lefthandside, ignoreVar); } - private Expression base_variable() { + private Expression base_variable(boolean lefthandside) { // base_variable: // reference_variable // | simple_indirect_reference reference_variable @@ -3118,7 +3118,7 @@ public class Parser implements ITerminalSymbols, CompilerModifiers, ParserBasicI while (token == TokenNameDOLLAR) { getNextToken(); } - reference_variable(false, false); + reference_variable(lefthandside, false); } return ref; }