|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35411 brace escape problem (changed behaviour)
Submitted: 2005-11-26 17:51 UTC Modified: 2005-11-27 07:49 UTC
From: frisauf at comnet dot cz Assigned: iliaa (profile)
Status: Closed Package: Strings related
PHP Version: 5.1.0 OS: linux
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: frisauf at comnet dot cz
New email:
PHP Version: OS:


 [2005-11-26 17:51 UTC] frisauf at comnet dot cz
I have found unexpected behaviour in PHP 5.1.0.

Escaping braces in strings doesn't work as in previous version.

Reproduce code:

echo "... {$string} ...\n";
echo "... \{$string} ...\n";

Expected result:
php 5.0.5:

... abc ...
... {abc} ...

Actual result:
php 5.1.0:

... abc ...
... {$string} ...


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-11-26 18:42 UTC]
This commit seems to be the cause:

I give infos to ilia, he likes to fix that.
 [2005-11-27 07:49 UTC]
This bug has been fixed in CVS.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
Thank you for the report, and for helping us make PHP better.

 [2014-02-16 23:55 UTC] mail at mkharitonov dot net
Behaviour is still not matched to the expected result.

Actual result (in php 5.5.9):
... abc ...
... \{abc} ...

Another example:
print "\{ \$";

Expected result:
{ $

Actual result (in php 5.5.9):
\{ $
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jul 22 20:01:29 2024 UTC