From: Andrei Zmievski Date: Tue, 19 Dec 2006 17:26:17 +0000 (+0000) Subject: Support 'b' prefix in front of string literals for forward compatibility X-Git-Tag: php-5.2.1RC2~148 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=16ea2ee6400990c4c21983d424eac6d77366d9c7;p=php Support 'b' prefix in front of string literals for forward compatibility with PHP 6. --- diff --git a/Zend/zend_language_scanner.l b/Zend/zend_language_scanner.l index 2be628fdcc..8c78d9674e 100644 --- a/Zend/zend_language_scanner.l +++ b/Zend/zend_language_scanner.l @@ -1707,13 +1707,13 @@ NEWLINE ("\r"|"\n"|"\r\n") } -["] { +b?["] { BEGIN(ST_DOUBLE_QUOTES); return '\"'; } -"<<<"{TABS_AND_SPACES}{LABEL}{NEWLINE} { +b?"<<<"{TABS_AND_SPACES}{LABEL}{NEWLINE} { char *s; CG(zend_lineno)++; CG(heredoc_len) = yyleng-3-1-(yytext[yyleng-2]=='\r'?1:0); @@ -1734,7 +1734,7 @@ NEWLINE ("\r"|"\n"|"\r\n") } -['] { +b?['] { BEGIN(ST_SINGLE_QUOTE); return '\''; }