Browse files

Merge pull request #505 from BenMorel/fix-errors

Fix errors in JoinClassPathExpression and SqlWalker
  • Loading branch information...
2 parents ff80e99 + 88b29a4 commit 6949a957826960e4cb8c4cf405a6c4528bbb2f84 @guilhermeblanco guilhermeblanco committed Nov 5, 2012
Showing with 2 additions and 4 deletions.
  1. +1 −1 lib/Doctrine/ORM/Query/AST/JoinClassPathExpression.php
  2. +1 −3 lib/Doctrine/ORM/Query/SqlWalker.php
View
2 lib/Doctrine/ORM/Query/AST/JoinClassPathExpression.php
@@ -40,6 +40,6 @@ public function __construct($abstractSchemaName, $aliasIdentificationVar)
public function dispatch($walker)
{
- return $sqlWalker->walkJoinPathExpression($this);
+ return $walker->walkJoinPathExpression($this);
}
}
View
4 lib/Doctrine/ORM/Query/SqlWalker.php
@@ -1172,7 +1172,7 @@ public function walkSelectExpression($selectExpression)
switch (true) {
case ($expr instanceof AST\PathExpression):
if ($expr->type !== AST\PathExpression::TYPE_STATE_FIELD) {
- throw QueryException::invalidPathExpression($expr->type);
+ throw QueryException::invalidPathExpression($expr);
}
$fieldName = $expr->field;
@@ -1213,7 +1213,6 @@ public function walkSelectExpression($selectExpression)
case ($expr instanceof AST\SimpleArithmeticExpression):
case ($expr instanceof AST\ArithmeticTerm):
case ($expr instanceof AST\ArithmeticFactor):
- case ($expr instanceof AST\ArithmeticPrimary):
case ($expr instanceof AST\Literal):
case ($expr instanceof AST\NullIfExpression):
case ($expr instanceof AST\CoalesceExpression):
@@ -1513,7 +1512,6 @@ public function walkSimpleSelectExpression($simpleSelectExpression)
case ($expr instanceof AST\SimpleArithmeticExpression):
case ($expr instanceof AST\ArithmeticTerm):
case ($expr instanceof AST\ArithmeticFactor):
- case ($expr instanceof AST\ArithmeticPrimary):
case ($expr instanceof AST\Literal):
case ($expr instanceof AST\NullIfExpression):
case ($expr instanceof AST\CoalesceExpression):

0 comments on commit 6949a95

Please sign in to comment.