helly           Thu May 18 21:48:33 2006 UTC

  Modified files:              (Branch: PHP_5_2)
    /php-src/ext/spl    spl_iterators.c 
  Log:
  - You shall not use %v in 5.*
  # Even though it is there it is only meant for pecl dev to ease their pain
  
  
http://cvs.php.net/viewcvs.cgi/php-src/ext/spl/spl_iterators.c?r1=1.73.2.30.2.6&r2=1.73.2.30.2.7&diff_format=u
Index: php-src/ext/spl/spl_iterators.c
diff -u php-src/ext/spl/spl_iterators.c:1.73.2.30.2.6 
php-src/ext/spl/spl_iterators.c:1.73.2.30.2.7
--- php-src/ext/spl/spl_iterators.c:1.73.2.30.2.6       Thu May 18 21:42:58 2006
+++ php-src/ext/spl/spl_iterators.c     Thu May 18 21:48:33 2006
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: spl_iterators.c,v 1.73.2.30.2.6 2006/05/18 21:42:58 helly Exp $ */
+/* $Id: spl_iterators.c,v 1.73.2.30.2.7 2006/05/18 21:48:33 helly Exp $ */
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
@@ -826,7 +826,7 @@
 
 #define SPL_CHECK_CTOR(intern, classname) \
        if (intern->dit_type == DIT_Unknown) { \
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "Classes derived from %v must call %v::__construct()", \
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "Classes derived from %s must call %s::__construct()", \
                                (spl_ce_##classname)->name, 
(spl_ce_##classname)->name); \
                return; \
        }
@@ -857,7 +857,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
        
        if (intern->dit_type != DIT_Unknown) {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v::getIterator() must be called exactly once per instance", 
ce_base->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s::getIterator() must be called exactly once per instance", 
ce_base->name);
                return NULL;
        }
 
@@ -926,7 +926,7 @@
                                if (instanceof_function(ce, zend_ce_aggregate 
TSRMLS_CC)) {
                                        
zend_call_method_with_0_params(&zobject, ce, 
&ce->iterator_funcs.zf_new_iterator, "getiterator", &retval);
                                        if (!retval || Z_TYPE_P(retval) != 
IS_OBJECT || !instanceof_function(Z_OBJCE_P(retval), zend_ce_traversable 
TSRMLS_CC)) {
-                                               
zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "%v::getIterator() 
must return an object that implememnts Traversable", ce->name);
+                                               
zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "%s::getIterator() 
must return an object that implememnts Traversable", ce->name);
                                                
php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
                                                return NULL;
                                        }
@@ -1777,7 +1777,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
 
        if (!(intern->u.caching.flags & 
(CIT_CALL_TOSTRING|CIT_TOSTRING_USE_KEY|CIT_TOSTRING_USE_CURRENT|CIT_TOSTRING_USE_INNER)))
      {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v does not fetch string value (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s does not fetch string value (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
        }
        if (intern->u.caching.flags & CIT_TOSTRING_USE_KEY) {
                if (intern->current.key_type == HASH_KEY_IS_STRING) {
@@ -1813,7 +1813,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
 
        if (!(intern->u.caching.flags & CIT_FULL_CACHE))        {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
        }
 
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz", &arKey, 
&nKeyLength, &value) == FAILURE) {
@@ -1837,7 +1837,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
 
        if (!(intern->u.caching.flags & CIT_FULL_CACHE))        {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
        }
 
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &arKey, 
&nKeyLength) == FAILURE) {
@@ -1864,7 +1864,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
 
        if (!(intern->u.caching.flags & CIT_FULL_CACHE))        {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
        }
 
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &arKey, 
&nKeyLength) == FAILURE) {
@@ -1886,7 +1886,7 @@
        intern = (spl_dual_it_object*)zend_object_store_get_object(getThis() 
TSRMLS_CC);
 
        if (!(intern->u.caching.flags & CIT_FULL_CACHE))        {
-               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%v does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
+               zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 
TSRMLS_CC, "%s does not use a full cache (see CachingIterator::__construct)", 
Z_OBJCE_P(getThis())->name);
        }
        
        if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &arKey, 
&nKeyLength) == FAILURE) {

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to