php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #42767 highlight_string() 'eats' the unclosed comment
Submitted: 2007-09-26 12:20 UTC Modified: 2009-05-09 00:46 UTC
Votes:1
Avg. Score:3.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (100.0%)
From: g0rn at mail dot ru Assigned: iliaa (profile)
Status: Closed Package: Scripting Engine problem
PHP Version: 5.2.4 OS: Linux
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: g0rn at mail dot ru
New email:
PHP Version: OS:

 

 [2007-09-26 12:20 UTC] g0rn at mail dot ru
Description:
------------
When I use highlight_string() on unclosed /* comment it doesn't returns anything, after this comment.

Reproduce code:
---------------
highlight_string('<?php /*some comment..');
highlight_string('<?php 
some code
some code
some code
/* some comment..');

Expected result:
----------------
In first example it should return:
<?php /*some comment..
In second:
<?php 
some code
some code
some code
/* some comment..

Actual result:
--------------
In first example it returns:
<?php
In second it returns:
<?php 
some code
some code
some code

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-09-26 15:46 UTC] iliaa@php.net
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
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Nov 07 23:01:29 2024 UTC