Exemple #1
0
 /**
  * Parses a here- or nowdoc string instance.
  *
  * @return PHP_Depend_Code_ASTHeredoc
  * @since 0.9.12
  */
 protected function parseHeredoc()
 {
     $this->tokenStack->push();
     $this->consumeToken(self::T_START_HEREDOC);
     $heredoc = $this->builder->buildAstHeredoc();
     $this->parseStringExpressions($heredoc, self::T_END_HEREDOC);
     $token = $this->consumeToken(self::T_END_HEREDOC);
     $heredoc->setDelimiter($token->image);
     return $this->setNodePositionsAndReturn($heredoc);
 }