#31425 [Opn->Bgs]: $string++ / $string-- ?

From: Date: Mon, 10 Jan 2005 13:43:12 +0000
Subject: #31425 [Opn->Bgs]: $string++ / $string-- ?
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-71713@lists.php.net to get a copy of this message
ID: 31425 Updated by: sniper@php.net Reported By: gregorschg at web dot de -Status: Open +Status: Bogus Bug Type: Performance problem Operating System: win xp PHP Version: 5.0.3 New Comment: RTFM: http://www.php.net/manual/en/language.operators.increment.php "Note that character variables can be incremented but not decremented." Previous Comments: ------------------------------------------------------------------------ [2005-01-08 20:17:59] gregorschg at web dot de sorry, I mean output of $letter is "C" and expected output of $letter is "B". ------------------------------------------------------------------------ [2005-01-06 06:35:30] gregorschg at web dot de Description: ------------ I have a problem to decreasing strings. Increasing a string works fine. Reproduce code: --------------- $letter = "C"; $letter--; echo "$letter"; Expected result: ---------------- output of $str >> "B" Actual result: -------------- output of $str >> "C" ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31425&edit=1

« previous php.bugs (#71713) next »