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_execute_API.c | |
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_execute_API.c')
-rw-r--r-- | Zend/zend_execute_API.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c index 5440103d7d..bce067597d 100644 --- a/Zend/zend_execute_API.c +++ b/Zend/zend_execute_API.c @@ -276,12 +276,10 @@ int call_user_function(HashTable *function_table, zval *object, zval *function_n return FAILURE; } function_table = &object->value.obj.ce->function_table; - /* unimplemented */ } original_function_state_ptr = EG(function_state_ptr); zend_str_tolower(function_name->value.str.val, function_name->value.str.len); if (zend_hash_find(function_table, function_name->value.str.val, function_name->value.str.len+1, (void **) &function_state.function)==FAILURE) { - zend_error(E_ERROR, "Unknown function: %s()\n", function_name->value.str.val); return FAILURE; } |