Bug #51581 [Com]: getDefaultProperties incorrect for static properties

2010-05-12 Thread ChadFulton at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=51581&edit=1

 ID:   51581
 Comment by:   ChadFulton at gmail dot com
 Reported by:  ChadFulton at gmail dot com
 Summary:  getDefaultProperties incorrect for static properties
 Status:   Assigned
 Type: Bug
 Package:  Reflection related
 Operating System: Mac OSx 10.6
 PHP Version:  5.3.2
 Assigned To:  dmitry

 New Comment:

Thanks for taking this issue up!


Previous Comments:

[2010-05-12 15:45:58] m...@php.net

Dmitry, could you please review the fix-refs-to-default-static-members
patch?



Thank you.


[2010-05-12 15:45:35] m...@php.net

The following patch has been added/updated:

Patch Name: fix-reflection-of-default-static-members
Revision:   1273671935
URL:   
http://bugs.php.net/patch-display.php?bug=51581&patch=fix-reflection-of-default-static-members&revision=1273671935


[2010-05-12 15:42:00] m...@php.net

The following patch has been added/updated:

Patch Name: fix-refs-to-default-static-members
Revision:   1273671720
URL:   
http://bugs.php.net/patch-display.php?bug=51581&patch=fix-refs-to-default-static-members&revision=1273671720


[2010-04-17 02:24:07] ChadFulton at gmail dot com

Description:

The array ReflectionClass's getDefaultProperties() method changes for
static 

properties, depending upon what value the static property currently
holds.



I suppose there is an argument to be made that this is expected/desired,
since 

static properties are meant to hold across all instances of the class.
However, it 

doesn't seem like it necessarily fits as part of a function to get the
*default* 

property.

Test script:
---
getDefaultProperties());



foo::$bar = 'new static value, no longer default though';



print_r($r->getDefaultProperties());



?>

Expected result:

Array

(

[bar] => true default value

)

Array

(

[bar] => true default value

)

Actual result:
--
Array

(

[bar] => true default value

)

Array

(

[bar] => new static value, no longer default though

)






-- 
Edit this bug report at http://bugs.php.net/bug.php?id=51581&edit=1


[PHP-BUG] Bug #51581 [NEW]: getDefaultProperties incorrect for static properties

2010-04-16 Thread ChadFulton at gmail dot com
From: 
Operating system: Mac OSx 10.6
PHP version:  5.3.2
Package:  Reflection related
Bug Type: Bug
Bug description:getDefaultProperties incorrect for static properties

Description:

The array ReflectionClass's getDefaultProperties() method changes for
static 

properties, depending upon what value the static property currently holds.



I suppose there is an argument to be made that this is expected/desired,
since 

static properties are meant to hold across all instances of the class.
However, it 

doesn't seem like it necessarily fits as part of a function to get the
*default* 

property.

Test script:
---
getDefaultProperties());



foo::$bar = 'new static value, no longer default though';



print_r($r->getDefaultProperties());



?>

Expected result:

Array

(

[bar] => true default value

)

Array

(

[bar] => true default value

)

Actual result:
--
Array

(

[bar] => true default value

)

Array

(

[bar] => new static value, no longer default though

)

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



#42608 [Com]: Example #660 (filter_input_array) is wrong

2009-10-07 Thread ChadFulton at gmail dot com
 ID:   42608
 Comment by:   ChadFulton at gmail dot com
 Reported By:  phpbugs dot 20 dot zsh at spamgourmet dot com
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: Irrelevant
 PHP Version:  5.2.4
 New Comment:

Although this is a very old bug, it seems to me that the poster is 
incorrect; I suspect the problem is that the poster attempted to set
the 
$_POST array during runtime (e.g. $_POST = array( ... ); ), and 
filter_input_array does not allow runtime modification $_POST, $_GET, 
etc.


Previous Comments:


[2007-09-10 11:04:44] phpbugs dot 20 dot zsh at spamgourmet dot com

Description:

The example will not output the array shown below the example code --
any undefined variable will cause filter_input_array() to return (so the
output would be "NULL").

You'll notice I've classified this as a change request rather than a
documentation problem, for the expected (and described ("Return
Values")) behavior in example #660 makes WAY more sense.

Reproduce code:
---
http://www.php.net/filter_input_array






-- 
Edit this bug report at http://bugs.php.net/?id=42608&edit=1