Skip to content

Commit

Permalink
Allow NULL in expressions.
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Ungureanu committed Dec 18, 2015
1 parent a023393 commit 47d03c5
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/Components/Expression.php
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ public static function parse(Parser $parser, TokensList $list, array $options =
if (($token->type === Token::TYPE_KEYWORD)
&& ($token->flags & Token::FLAG_KEYWORD_RESERVED)
&& ($token->value !== 'DUAL')
&& ($token->value !== 'NULL')
) {
// Keywords may be found only between brackets.
if ($brackets === 0) {
Expand Down
1 change: 1 addition & 0 deletions src/Components/ExpressionArray.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ public static function parse(Parser $parser, TokensList $list, array $options =
&& ($token->flags & Token::FLAG_KEYWORD_RESERVED)
&& ((~$token->flags & Token::FLAG_KEYWORD_FUNCTION))
&& ($token->value !== 'DUAL')
&& ($token->value !== 'NULL')
) {
// No keyword is expected.
break;
Expand Down
1 change: 0 additions & 1 deletion src/Statement.php
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@ public function build()
if (!empty($built[$field])) {
continue;
}

$built[$field] = true;
}

Expand Down

0 comments on commit 47d03c5

Please sign in to comment.