Date: 09/25/98
- Next message: danny: "[PHP-DEV] CVS update: php3/functions"
- Previous message: Bug Database: "[PHP-DEV] Bug #549 Updated: gcc compiler error?"
- In reply to: Bug Database: "[PHP-DEV] Bug #786 Updated: Incorrect expression evaluation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Bug Database writes:
> ID: 786
> Updated by: zeev
> Reported By: torben <email protected>
> Status: Closed
> Bug Type: Performance problem
> Assigned To:
> Comments:
>
> When one the arguments to a comparison operator is a number,
> or a string that looks like a number, the comparison is
> done numerically. In this case, 'r' is converted to a 0
> (like any other non-numeric string), and thus the comparison
> evaluates to TRUE.
>
> If you know you want a string comparison, you should use
> strcmp() instead.
>
> Full Bug description available at: http://ca.php.net/bugs.php3?id=786
3 AM brainfart from hell, there. Had I just remembered what I wrote in
the Type Juggling chapter...*sigh*...
Thanks
Torben
-- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe <email protected> For help: php-dev-help <email protected>
- Next message: danny: "[PHP-DEV] CVS update: php3/functions"
- Previous message: Bug Database: "[PHP-DEV] Bug #549 Updated: gcc compiler error?"
- In reply to: Bug Database: "[PHP-DEV] Bug #786 Updated: Incorrect expression evaluation"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

