#48689 [NEW]: Allow for dynamic class constants via magic method __constant()
From: RQuadling at GoogleMail dot com Operating system: Irrelevant PHP version: 5.3.0RC4 PHP Bug Type: Feature/Change Request Bug description: Allow for dynamic class constants via magic method __constant() Description: Hi. Would it be possible to have a new magic method allowing a class to handle a request for a constant that has not been defined. http://bugs.php.net/?id=48689&edit=1 -- Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=48689&r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=48689&r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=48689&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=48689&r=fixedcvs Fixed in CVS and need be documented: http://bugs.php.net/fix.php?id=48689&r=needdocs Fixed in release: http://bugs.php.net/fix.php?id=48689&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=48689&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=48689&r=needscript Try newer version: http://bugs.php.net/fix.php?id=48689&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=48689&r=support Expected behavior: http://bugs.php.net/fix.php?id=48689&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=48689&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=48689&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=48689&r=globals PHP 4 support discontinued: http://bugs.php.net/fix.php?id=48689&r=php4 Daylight Savings:http://bugs.php.net/fix.php?id=48689&r=dst IIS Stability: http://bugs.php.net/fix.php?id=48689&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=48689&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=48689&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=48689&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=48689&r=mysqlcfg
#48704 [NEW]: preg_split with limit issues similar to old explode limit issues.
From: RQuadling at GoogleMail dot com Operating system: Windows XP SP3 PHP version: 5.3CVS-2009-06-26 (CVS) PHP Bug Type: PCRE related Bug description: preg_split with limit issues similar to old explode limit issues. Description: This comes from the recent opened doc bug (http://bugs.php.net/bug.php? id=48703) and fixed bug http://bugs.php.net/bug.php?id=47560. In #48703, the OP says that the limit on preg_split() should be documented the same as the limit in explode (split). But the following code shows that the output is different in certain circumstances. For #48703 to be closed with the documentation being updated to match that of explode, then preg_split() needs to be amended to match the behaviour of explode with regards to the limit parameter. Reproduce code: --- '.', 'Invalid' => '_') as $valid => $delimiter) { $results[$valid]['No Limit'] = explode($delimiter, $string); foreach(range(-4, 4) as $limit) { $explode= explode($delimiter, $string, $limit); $preg_split = preg_split("`\\{$delimiter}`", $string, $limit); if (serialize($explode) !== serialize($preg_split)) { echo "BAD: Output does not match for a delimiter of '$delimiter' ($valid) and a limit of $limit.", PHP_EOL, 'EXPLODE: ', implode(' : ', $explode), PHP_EOL, 'PREG_SPLIT : ', implode(' : ', $preg_split), PHP_EOL, PHP_EOL; } else { echo "GOOD : Output does match for a delimiter of '$delimiter' ($valid) and a limit of $limit.", PHP_EOL, PHP_EOL; } } } Expected result: GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of -4. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of -3. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of -2. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of -1. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of 0. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of 1. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of 2. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of 3. GOOD : Output does not match for a delimiter of '.' (Valid) and a limit of 4. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of -4. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of -3. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of -2. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of -1. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of 0. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of 1. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of 2. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of 3. GOOD : Output does not match for a delimiter of '_' (Invalid) and a limit of 4. Actual result: -- BAD: Output does not match for a delimiter of '.' (Valid) and a limit of -4. EXPLODE: PREG_SPLIT : one.two.three.four BAD: Output does not match for a delimiter of '.' (Valid) and a limit of -3. EXPLODE: one PREG_SPLIT : one.two.three.four BAD: Output does not match for a delimiter of '.' (Valid) and a limit of -2. EXPLODE: one : two PREG_SPLIT : one.two.three.four BAD: Output does not match for a delimiter of '.' (Valid) and a limit of -1. EXPLODE: one : two : three PREG_SPLIT : one : two : three : four BAD: Output does not match for a delimiter of '.' (Valid) and a limit of 0. EXPLODE: one.two.three.four PREG_SPLIT : one : two : three : four GOOD : Output does match for a delimiter of '.' (Valid) and a limit of 1. GOOD : Output does match for a delimiter of '.' (Valid) and a limit of 2. GOOD : Output does match for a delimiter of '.' (Valid) and a limit of 3. GOOD : Output does match for a delimiter of '.' (Valid) and a limit of 4. BAD: Output does not match for a delimiter of '_' (Invalid) and a limit of -4. EXPLODE: PREG_SPLIT : one.two.three.four BAD: Output does not match for a delimiter of '_' (Inval
#49458 [Com]: passthru is unable to fork
ID: 49458 Comment by: RQuadling at GoogleMail dot com Reported By: RQuadling at GMail dot com Status: Feedback Bug Type: Filesystem function related Operating System: Windows XP SP3 PHP Version: 5.3SVN-2009-09-03 (SVN) Assigned To: pajoye New Comment: [2009/09/03 16:18:38] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] >php -n -v PHP 5.3.1-dev (cli) (built: Sep 3 2009 10:16:30) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies [2009/09/03 16:18:40] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] >php -n -r "echo passthru('php.exe -n -v');" Warning: passthru(): Unable to fork [php.exe -v] in Command line code on line 1 [2009/09/03 16:18:48] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] > Basically, all the latest snapshots from windows.php.net are failing for me. All the official releases are working for me. Checking historical versions ... PHP 5.3.1-dev (cli) (built: Aug 27 2009 23:21:09) Works PHP 5.3.1-dev (cli) (built: Aug 28 2009 00:20:34) Works PHP 5.3.1-dev (cli) (built: Aug 28 2009 01:20:31) Works I'll get the historical updates and let you know when the failure started. Have you got any uncommitted code? Previous Comments: [2009-09-03 15:31:54] RQuadling at GMail dot com [2009/09/03 16:18:38] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] >php -n -v PHP 5.3.1-dev (cli) (built: Sep 3 2009 10:16:30) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies [2009/09/03 16:18:40] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] >php -n -r "echo passthru('php.exe -n -v');" Warning: passthru(): Unable to fork [php.exe -v] in Command line code on line 1 [2009/09/03 16:18:48] [D:\Personal Files\Downloads\Software\Programming\PHP\Latest Snapshots\php-5.3-nts- win32-VC6-x86-latest] [] > Basically, all the latest snapshots from windows.php.net are failing for me. All the official releases are working for me. Checking historical versions ... PHP 5.3.1-dev (cli) (built: Aug 27 2009 23:21:09) Works PHP 5.3.1-dev (cli) (built: Aug 28 2009 00:20:34) Works PHP 5.3.1-dev (cli) (built: Aug 28 2009 01:20:31) Works I'll get the historical updates and let you know when the failure started. Have you got any uncommitted code? [2009-09-03 14:54:12] paj...@php.net Which version do you use? It works here using vc9/x86 [2009-09-03 14:46:51] RQuadling at GMail dot com Description: Unable to fork. As a consequence, phpdoc/configure.php fails on windows as it is unable to call external scripts. Run the command below at the command prompt. This works on PHP 5.3.0 (cli) (built: Jun 29 2009 21:44:56) Reproduce code: --- php -n -r "echo passthru('php.exe -v');" Expected result: PHP 5.3.1-dev (cli) (built: Sep 3 2009 09:58:01) Copyright (c) 1997-2009 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies Actual result: -- Warning: passthru(): Unable to fork [php.exe -v] in Command line code on line 1 -- Edit this bug report at http://bugs.php.net/?id=49458&edit=1