public function AbstractLexer::glimpse in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/doctrine/lexer/lib/Doctrine/Common/Lexer/AbstractLexer.php \Doctrine\Common\Lexer\AbstractLexer::glimpse()
Peeks at the next token, returns it and immediately resets the peek.
Return value
array|null The next token or NULL if there are no more tokens ahead.
File
- vendor/
doctrine/ lexer/ lib/ Doctrine/ Common/ Lexer/ AbstractLexer.php, line 231
Class
- AbstractLexer
- Base class for writing simple lexers, i.e. for creating small DSLs.
Namespace
Doctrine\Common\LexerCode
public function glimpse() {
$peek = $this
->peek();
$this->peek = 0;
return $peek;
}