public static function parseDocString($startToken, $str)
    {
        // strip last newline (thanks tokenizer for sticking it into the string!)
        $str = preg_replace('~(\r\n|\n|\r)$~', '', $str);

        // nowdoc string
        if (false !== strpos($startToken, '\'')) {
            return $str;
        }

        return self::parseEscapeSequences($str, null);
    }
public static function parseDocString($startToken, $str)
    {
        // strip last newline (thanks tokenizer for sticking it into the string!)
        $str = preg_replace('~(\r\n|\n|\r)$~', '', $str);

        // nowdoc string
        if (false !== strpos($startToken, '\'')) {
            return $str;
        }

        return self::parseEscapeSequences($str, null);
    }
public static function parseDocString ( $ startToken , $ str ) { // strip last newline (thanks tokenizer for sticking it into the string!) $ str = preg_replace ( '~(\r\n|\n|\r)$~' , '' , $ str ) ; // nowdoc string if ( false !== strpos ( $ startToken , '\'' ) ) { return $ str ; } return self :: parseEscapeSequences ( $ str , null ) ; }
Parses a constant doc string.

@param string $startToken Doc string start token content (<<<SMTHG)
@param string $str        String token content

@return string Parsed string
Parses a constant doc string .