Bug #65728 [NEW]: \DateInterval->days turns from boolean to integer value
| From: | sebastiankuhlmann at web dot de | Date: | Fri, 20 Sep 2013 14:28:38 +0000 |
| Subject: | Bug #65728 [NEW]: \DateInterval->days turns from boolean to integer value | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-181715@lists.php.net to get a copy of this message | ||
From: sebastiankuhlmann at web dot de
Operating system: independant
PHP version: Irrelevant
Package: Date/time related
Bug Type: Bug
Bug description:\DateInterval->days turns from boolean to integer value
Description:
------------
When creating a \DateInterval()-object according to the documentation the
'days'-property should be false. A var_dump on the object confirms this.
Now if you do a var_dump directly on the 'days'-property the var-type and
-value changes from FALSE to -99999.
https://bugs.php.net/bug.php?id=65654 might be
related to this.
Test script:
---------------
$test = new \DateInterval('P1D');
var_dump($test->days);
Expected result:
----------------
bool(false)
Actual result:
--------------
int(-99999)
--
Edit bug report at https://bugs.php.net/bug.php?id=65728&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65728&r=trysnapshot54
Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65728&r=trysnapshot53
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65728&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=65728&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=65728&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=65728&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=65728&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=65728&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=65728&r=support
Expected behavior: https://bugs.php.net/fix.php?id=65728&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=65728&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=65728&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=65728&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65728&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=65728&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=65728&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=65728&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=65728&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=65728&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=65728&r=mysqlcfg