#28223 [NEW]: unary minus operator is not documented
| From: | krenya at inf dot bme dot hu | Date: | Thu, 29 Apr 2004 20:49:02 +0000 |
| Subject: | #28223 [NEW]: unary minus operator is not documented | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969360345@lists.php.net to get a copy of this message | ||
From: krenya at inf dot bme dot hu
Operating system: any
PHP version: 4.3.6
PHP Bug Type: Documentation problem
Bug description: unary minus operator is not documented
Description:
------------
"Table 10-1. Operator Precedence" and "Table 10-2. Arithmetic Operators"
tables do not include the "unary minus" operator although it exists in
php.
Please add itt to the two table above.
Thanx
Reproduce code:
---------------
<?
$a = 1;
$a = -$a;
echo $a;
?>
Expected result:
----------------
PARSE error as there's no unary minus operator according to the docs
Actual result:
--------------
ouputs "-1"
--
Edit bug report at http://bugs.php.net/?id=28223&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=28223&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=28223&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=28223&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=28223&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=28223&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=28223&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=28223&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=28223&r=support
Expected behavior: http://bugs.php.net/fix.php?id=28223&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=28223&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=28223&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=28223&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=28223&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=28223&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=28223&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=28223&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=28223&r=float