mirror of
https://github.com/php/php-src.git
synced 2024-11-24 10:24:11 +08:00
Merge branch 'PHP-7.0'
Conflicts: Zend/zend_language_scanner.c
This commit is contained in:
commit
35b34d7235
19
Zend/tests/bug71724.phpt
Normal file
19
Zend/tests/bug71724.phpt
Normal file
@ -0,0 +1,19 @@
|
||||
--TEST--
|
||||
Bug #71724: yield from does not count EOLs
|
||||
--FILE--
|
||||
<?php
|
||||
|
||||
function test()
|
||||
{
|
||||
yield
|
||||
|
||||
|
||||
|
||||
|
||||
from [__LINE__];
|
||||
}
|
||||
var_dump(test()->current());
|
||||
|
||||
?>
|
||||
--EXPECT--
|
||||
int(10)
|
File diff suppressed because it is too large
Load Diff
@ -1128,6 +1128,7 @@ NEWLINE ("\r"|"\n"|"\r\n")
|
||||
}
|
||||
|
||||
<ST_IN_SCRIPTING>"yield"{WHITESPACE}"from" {
|
||||
HANDLE_NEWLINES(yytext, yyleng);
|
||||
RETURN_TOKEN(T_YIELD_FROM);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user