From:             tim dot whitlock at whiteinteractive dot com
Operating system: Mac OS X 10.4
PHP version:      4.4.5
PHP Bug Type:     Unknown/Other Function
Bug description:  Tokenizer fails to parse T_OPEN_TAG

Description:
------------
I have seen a report of this in bug #29761, but it is *NOT FIXED*
Actually I am on 4.4.4, but nothing in changelog about a fix in 4.4.5, or
4.4.6.

*Sometimes* token_get_all breaks T_OPEN_TAG into three separate entities.
This is inconsistent, and I don't know what variable causes the glitch,
(memory?)

Restarting web server fixes temporarily, but its back after a number of
requests. I might have to refresh web page 50 times to see it break, but it
will break eventually.

This glitch is fixable in PHP client code, but annoying and unnecessary


Reproduce code:
---------------
print_r( token_get_all( '<?php ' ) );

Expected result:
----------------
Array
(
    [0] => Array
        (
            [0] => 354
            [1] => <?php 
        )

)


// Where 354 === T_OPEN_TAG

Actual result:
--------------
Array
(
    [0] => <
    [1] => ?
    [2] => Array
        (
            [0] => 305
            [1] => php 
        )

)


// Where 305 === T_STRING

-- 
Edit bug report at http://bugs.php.net/?id=41002&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=41002&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=41002&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=41002&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=41002&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=41002&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=41002&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=41002&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=41002&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=41002&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=41002&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=41002&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=41002&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=41002&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=41002&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=41002&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=41002&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=41002&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=41002&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=41002&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=41002&r=mysqlcfg

Reply via email to