diff options
author | Sterling Hughes <sterling@php.net> | 2003-05-21 18:46:34 +0000 |
---|---|---|
committer | Sterling Hughes <sterling@php.net> | 2003-05-21 18:46:34 +0000 |
commit | 5619166fe4b97404ead038b5485f33c56d21885f (patch) | |
tree | d8a8ca02f179e7b003b2967a93dad9496e7dc7e9 /Zend/zend_operators.c | |
parent | 7b26ddd9b01fb242f5a6ec3ada5804a8019f4e5b (diff) | |
download | php-git-5619166fe4b97404ead038b5485f33c56d21885f.tar.gz |
optimize loops. The check only exists for integers because that's the more
common optimization, and you actually lose performance if you check for
a double too (wierd but true).
Diffstat (limited to 'Zend/zend_operators.c')
-rw-r--r-- | Zend/zend_operators.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c index 8915ca90a4..f89d119fc5 100644 --- a/Zend/zend_operators.c +++ b/Zend/zend_operators.c @@ -144,7 +144,9 @@ ZEND_API void convert_scalar_to_number(zval *op TSRMLS_DC) #define zendi_convert_scalar_to_number(op, holder, result) \ if (op==result) { \ - convert_scalar_to_number(op TSRMLS_CC); \ + if (op->type != IS_LONG) { \ + convert_scalar_to_number(op TSRMLS_CC); \ + } \ } else { \ switch ((op)->type) { \ case IS_STRING: \ |