From 1681d8a8933211c44edff633f69ad5f4cc6f515e Mon Sep 17 00:00:00 2001 From: Christian Raue Date: Mon, 10 Oct 2011 14:04:55 +0200 Subject: [PATCH] switched 2nd and 3rd argument for SelectExpression's constructor, making the 3rd one optional to keep its signature compatible to previous versions --- lib/Doctrine/ORM/Query/AST/SelectExpression.php | 6 +++--- lib/Doctrine/ORM/Query/Parser.php | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/Doctrine/ORM/Query/AST/SelectExpression.php b/lib/Doctrine/ORM/Query/AST/SelectExpression.php index 623a325bb..e3c917200 100644 --- a/lib/Doctrine/ORM/Query/AST/SelectExpression.php +++ b/lib/Doctrine/ORM/Query/AST/SelectExpression.php @@ -36,14 +36,14 @@ namespace Doctrine\ORM\Query\AST; class SelectExpression extends Node { public $expression; - public $hiddenAliasResultVariable; public $fieldIdentificationVariable; + public $hiddenAliasResultVariable; - public function __construct($expression, $hiddenAliasResultVariable, $fieldIdentificationVariable) + public function __construct($expression, $fieldIdentificationVariable, $hiddenAliasResultVariable = false) { $this->expression = $expression; - $this->hiddenAliasResultVariable = $hiddenAliasResultVariable; $this->fieldIdentificationVariable = $fieldIdentificationVariable; + $this->hiddenAliasResultVariable = $hiddenAliasResultVariable; } public function dispatch($sqlWalker) diff --git a/lib/Doctrine/ORM/Query/Parser.php b/lib/Doctrine/ORM/Query/Parser.php index 35294a0ea..08e036c1a 100644 --- a/lib/Doctrine/ORM/Query/Parser.php +++ b/lib/Doctrine/ORM/Query/Parser.php @@ -1921,7 +1921,7 @@ class Parser } } - $expr = new AST\SelectExpression($expression, $hiddenAliasResultVariable, $fieldAliasIdentificationVariable); + $expr = new AST\SelectExpression($expression, $fieldAliasIdentificationVariable, $hiddenAliasResultVariable); if ( ! $supportsAlias) { $this->_identVariableExpressions[$identVariable] = $expr;