php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #71724 yield from does not count EOLs
Submitted: 2016-03-06 20:17 UTC Modified: 2018-11-23 09:21 UTC
From: dragondreamer at live dot com Assigned:
Status: Closed Package: *Compile Issues
PHP Version: 7.0.4 OS: Any
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: dragondreamer at live dot com
New email:
PHP Version: OS:

 

 [2016-03-06 20:17 UTC] dragondreamer at live dot com
Description:
------------
PHP lexer does not count new lines which can be inserted between "yield" and "from" words in "yield from" instruction.

Test script:
---------------
<?php

function test()
{
    yield
    
    
    
    
    from [3, 4];
}

123


Expected result:
----------------
Parse error: syntax error, unexpected end of file in /in/7Hocc on line 13

Actual result:
--------------
Parse error: syntax error, unexpected end of file in /in/7Hocc on line 8

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2016-03-06 20:40 UTC] nikic@php.net
Automatic comment on behalf of nikic
Revision: http://git.php.net/?p=php-src.git;a=commit;h=860dc17ab758683a121d66a625308bdfbbcad5c4
Log: Fixed bug #71724
 [2016-03-06 20:40 UTC] nikic@php.net
-Status: Open +Status: Closed
 [2016-07-20 11:33 UTC] davey@php.net
Automatic comment on behalf of nikic
Revision: http://git.php.net/?p=php-src.git;a=commit;h=860dc17ab758683a121d66a625308bdfbbcad5c4
Log: Fixed bug #71724
 [2018-11-23 09:21 UTC] dragondreamer at live dot com
-: temp at temp dot ru +: dragondreamer at live dot com
 [2018-11-23 09:21 UTC] dragondreamer at live dot com
Edit e-mail address
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Oct 15 09:01:26 2024 UTC