#25626 [Opn->Bgs]: Variables containing number starting with 0 (Zero) become 0 (Zero)
| From: | sniper@php.net | Date: | Mon, 22 Sep 2003 10:53:56 +0000 |
| Subject: | #25626 [Opn->Bgs]: Variables containing number starting with 0 (Zero) become 0 (Zero) | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-47939@lists.php.net to get a copy of this message | ||
ID: 25626
Updated by: sniper@php.net
Reported By: sameh dot attia at tedata dot net
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: RHL 9
PHP Version: 4.3.3
New Comment:
RTFM: http://www.php.net/manual/en/language.types.integer.php
About what is octal number..
Previous Comments:
------------------------------------------------------------------------
[2003-09-22 06:23:44] sameh dot attia at tedata dot net
Description:
------------
If u assigned a variable x any value that starts with 0; like 09; then
the value inside the varaible becomes 0.
This also happens when calling functions; paramters passed to the
function suffer the same bug.
Reproduce code:
---------------
<?php
$VarX = 09;
echo "VarX = $VarX\n";
FunY(09);
function FunY($VarY)
{
echo "VarY = $VarY\n";
}
?>
Expected result:
----------------
VarX = 09
VarY = 09
Actual result:
--------------
VarX = 0
VarY = 0
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=25626&edit=1