php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #6251 Characters after end of heredoc cause parse error.
Submitted: 2000-08-18 20:34 UTC Modified: 2000-08-18 20:35 UTC
From: torben@php.net Assigned:
Status: Closed Package: Scripting Engine problem
PHP Version: 4.0 Latest CVS (18/08/2000) OS: Mandrake Linux 7.0
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: torben@php.net
New email:
PHP Version: OS:

 

 [2000-08-18 20:34 UTC] torben@php.net
<?php
error_reporting(E_ALL);

$str = <<<EOT
When anything but a newline or carriage return--even 
whitespace, or a comment--comes after the semicolon after 
the heredoc closing label (on the same line), a parse 
error is generated.
EOT; 

echo $str;
?>

This was compiled from cvs last night; configure line:

./configure \
   --with-java \
   --with-mysql=/usr/local/mysql \
   --with-gd \
   --with-apxs=/usr/local/apache/bin/apxs \
   --enable-versioning \
   --enable-track-vars \
   --enable-sysvshm \
   --disable-debug \
   --with-xml \
   --with-dom=/usr/lib


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-08-18 20:35 UTC] stas@php.net
This is intentional. And we already have a feature request to change this, and maybe it will be implemented.
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Sat Oct 10 11:00:01 2026 UTC