]> granicus.if.org Git - php/commitdiff
- MFH: Print the type of the original value
authorJohannes Schlüter <johannes@php.net>
Mon, 11 Sep 2006 21:21:43 +0000 (21:21 +0000)
committerJohannes Schlüter <johannes@php.net>
Mon, 11 Sep 2006 21:21:43 +0000 (21:21 +0000)
ext/reflection/php_reflection.c

index bd63658c8b6a4679afa67bb3b006e0ed74309544..bca4032f99c0b14c4ace225bfaf2127bdb69376f 100644 (file)
@@ -537,9 +537,12 @@ static void _class_string(string *str, zend_class_entry *ce, zval *obj, char *in
 /* {{{ _const_string */
 static void _const_string(string *str, char *name, zval *value, char *indent TSRMLS_DC)
 {
+       char *type;
        zval value_copy;
        int use_copy;
 
+       type = zend_zval_type_name(value);
+
        zend_make_printable_zval(value, &value_copy, &use_copy);
        if (use_copy) {
                value = &value_copy;
@@ -547,7 +550,7 @@ static void _const_string(string *str, char *name, zval *value, char *indent TSR
 
        string_printf(str, "%s    Constant [ %s %s ] { %s }\n",
                           indent,
-                          zend_zval_type_name(value),
+                          type,
                           name,
                           Z_STRVAL_P(value));