diff options
| author | Zeev Suraski <zeev@php.net> | 1999-06-11 10:44:26 +0000 |
|---|---|---|
| committer | Zeev Suraski <zeev@php.net> | 1999-06-11 10:44:26 +0000 |
| commit | da9faa2c3a7db0f222e751e899c843a1f6561e8b (patch) | |
| tree | eb7a22ce11a5935885bee80bc0d7bf418ac7d529 /Zend/zend.h | |
| parent | 1798a0183a962342948bd9110435994d87853a8b (diff) | |
| download | php-git-da9faa2c3a7db0f222e751e899c843a1f6561e8b.tar.gz | |
* Make the output handling of variables much, much cooler.
Uses zend_make_printable_zval() instead of convert_to_string() now:
$foo = true;
print "\$foo is $foo";
will now print
$foo is true
(instead of "$foo is 1", earlier).
Also, with objects, it automatically tries to call __print() and use it as a printing
function.
For example:
class foo {
function __print() { return "Foo Object"; }
};
$foo = new foo;
print $foo;
will print "Foo Object".
Diffstat (limited to 'Zend/zend.h')
| -rw-r--r-- | Zend/zend.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Zend/zend.h b/Zend/zend.h index ece884f84a..56fd918bcf 100644 --- a/Zend/zend.h +++ b/Zend/zend.h @@ -180,6 +180,7 @@ ZEND_API void zend_bailout(); END_EXTERN_C() ZEND_API char *get_zend_version(); +ZEND_API void zend_make_printable_zval(zval *expr, zval *expr_copy, int *use_copy); ZEND_API int zend_print_zval(zval *expr, int indent); ZEND_API void zend_print_zval_r(zval *expr, int indent); |
