+++ /dev/null
---TEST--
-No warnings should be thrown during heredoc scan-ahead
---FILE--
-<?php
-
-<<<TEST
-\400
-${/*}
-TEST;
-
-?>
---EXPECTF--
-Warning: Octal escape sequence overflow \400 is greater than \377 in %s on line %d
-
-Warning: Unterminated comment starting line %d in %s on line %d
-
-Parse error: syntax error, unexpected end of file in %s on line %d
if (YYCURSOR < YYLIMIT) {
YYCURSOR++;
- } else if (!SCNG(heredoc_scan_ahead)) {
- zend_error(E_COMPILE_WARNING, "Unterminated comment starting line %d", CG(zend_lineno));
+ } else {
+ zend_throw_exception_ex(zend_ce_parse_error, 0, "Unterminated comment starting line %d", CG(zend_lineno));
+ if (PARSER_MODE()) {
+ RETURN_TOKEN(T_ERROR);
+ }
}
yyleng = YYCURSOR - SCNG(yy_text);