aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorifriedman2014-01-08 08:01:00 (EST)
committerifriedman2014-01-08 08:01:00 (EST)
commit812394e80a0269a28b5053e6896eb09521ec9ff1 (patch)
tree86df00e1a7730a5526066050a650d757bf732aa0
parent85163d37e33dc5a5ac5467e2b830031df8933cc1 (diff)
downloadorg.eclipse.pdt-812394e80a0269a28b5053e6896eb09521ec9ff1.zip
org.eclipse.pdt-812394e80a0269a28b5053e6896eb09521ec9ff1.tar.gz
org.eclipse.pdt-812394e80a0269a28b5053e6896eb09521ec9ff1.tar.bz2
Bug 424811 - PHP 5.5 - empty should support arbitrary expressionsrefs/changes/76/20376/1
Change-Id: Icad517ced7a0ad6ef0cbe644e425c05abea43f28 Signed-off-by: ifriedman <itay.f@zend.com>
-rw-r--r--plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_ast_parser.cup8
-rw-r--r--plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_compiler_ast_parser.cup8
2 files changed, 8 insertions, 8 deletions
diff --git a/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_ast_parser.cup b/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_ast_parser.cup
index 07f8984..342fd3d 100644
--- a/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_ast_parser.cup
+++ b/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_ast_parser.cup
@@ -3331,12 +3331,12 @@ T_ISSET:s T_OPEN_PARENTHESE isset_variables:varList T_CLOSE_PARENTHESE:e
new Identifier(sleft, sright, parser.ast, "isset")), varList);
:}
-| T_EMPTY:s T_OPEN_PARENTHESE variable:var T_CLOSE_PARENTHESE:e
+| T_EMPTY:s T_OPEN_PARENTHESE expr:expr T_CLOSE_PARENTHESE:e
{:
- LinkedList varList = new LinkedList();
- varList.add(var);
+ LinkedList exprList = new LinkedList();
+ exprList.add(expr);
RESULT = new FunctionInvocation(sleft, eright, parser.ast,
- new FunctionName(sleft, sright, parser.ast, new Identifier(sleft, sright, parser.ast, "empty")), varList);
+ new FunctionName(sleft, sright, parser.ast, new Identifier(sleft, sright, parser.ast, "empty")), exprList);
:}
| T_INCLUDE:include expr:expr
diff --git a/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_compiler_ast_parser.cup b/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_compiler_ast_parser.cup
index f0b7b7a..0046322 100644
--- a/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_compiler_ast_parser.cup
+++ b/plugins/org.eclipse.php.core/Resources/parserTools/parser/php55/php_compiler_ast_parser.cup
@@ -3813,12 +3813,12 @@ T_ISSET:start T_OPEN_PARENTHESE:openPar isset_variables:varList T_CLOSE_PARENTHE
RESULT = result;
:}
-| T_EMPTY:start T_OPEN_PARENTHESE:openPar variable:var T_CLOSE_PARENTHESE:end
+| T_EMPTY:start T_OPEN_PARENTHESE:openPar expr:expr T_CLOSE_PARENTHESE:end
{:
SimpleReference name = new SimpleReference(startleft, startright, "empty");
- PHPCallArgumentsList varList = new PHPCallArgumentsList(openParright, endleft);
- varList.addNode(var);
- PHPCallExpression result = new PHPCallExpression(startleft, endright, null, name, varList);
+ PHPCallArgumentsList exprList = new PHPCallArgumentsList(openParright, endleft);
+ exprList.addNode(expr);
+ PHPCallExpression result = new PHPCallExpression(startleft, endright, null, name, exprList);
RESULT = result;
:}