src/Luminous/Scanners/PerlScanner.php
public function heredocRealOverride($matches)
    {
        $this->record($matches[0], null);
        $this->posShift(strlen($matches[0]));
        // don't need this anymore
        $this->removePattern('HEREDOC_NL');
        assert($this->heredoc !== null);
        $delim = preg_quote($this->heredoc);
        $substr = $this->scanUntil('/^' . $delim . '\\b/m');
        if ($substr !== null) {
            $this->record($substr, 'HEREDOC');
            $delim_ = $this->scan('/' . $delim . '/');
            assert($delim !== null);
            $this->record($delim_, 'DELIMITER');
        } else {
            $this->record($this->rest(), 'HEREDOC');
            $this->terminate();
        }
    }
public function heredocRealOverride($matches)
    {
        $this->record($matches[0], null);
        $this->posShift(strlen($matches[0]));
        // don't need this anymore
        $this->removePattern('HEREDOC_NL');
        assert($this->heredoc !== null);
        $delim = preg_quote($this->heredoc);
        $substr = $this->scanUntil('/^' . $delim . '\\b/m');
        if ($substr !== null) {
            $this->record($substr, 'HEREDOC');
            $delim_ = $this->scan('/' . $delim . '/');
            assert($delim !== null);
            $this->record($delim_, 'DELIMITER');
        } else {
            $this->record($this->rest(), 'HEREDOC');
            $this->terminate();
        }
    }
public function heredocRealOverride ( $ matches ) { $ this -> record ( $ matches [ 0 ] , null ) ; $ this -> posShift ( strlen ( $ matches [ 0 ] ) ) ; // don't need this anymore $ this -> removePattern ( 'HEREDOC_NL' ) ; assert ( $ this -> heredoc !== null ) ; $ delim = preg_quote ( $ this -> heredoc ) ; $ substr = $ this -> scanUntil ( '/^' . $ delim . '\\b/m' ) ; if ( $ substr !== null ) { $ this -> record ( $ substr , 'HEREDOC' ) ; $ delim_ = $ this -> scan ( '/' . $ delim . '/' ) ; assert ( $ delim !== null ) ; $ this -> record ( $ delim_ , 'DELIMITER' ) ; } else { $ this -> record ( $ this -> rest ( ) , 'HEREDOC' ) ; $ this -> terminate ( ) ; } }
this override handles the actual heredoc text
this override handles the actual heredoc text