}
-/* {{{ proto string zend_version(void)
+/* {{{ proto string zend_version(void) U
Get the version of the Zend Engine */
ZEND_FUNCTION(zend_version)
{
/* }}} */
-/* {{{ proto int func_num_args(void)
+/* {{{ proto int func_num_args(void) U
Get the number of arguments that were passed to the function */
ZEND_FUNCTION(func_num_args)
{
/* }}} */
-/* {{{ proto mixed func_get_arg(int arg_num)
+/* {{{ proto mixed func_get_arg(int arg_num) U
Get the $arg_num'th argument that was passed to the function */
ZEND_FUNCTION(func_get_arg)
{
/* }}} */
-/* {{{ proto array func_get_args()
+/* {{{ proto array func_get_args() U
Get an array of the arguments that were passed to the function */
ZEND_FUNCTION(func_get_args)
{
/* }}} */
-/* {{{ proto int strlen(string str)
+/* {{{ proto int strlen(string str) U
Get string length */
ZEND_NAMED_FUNCTION(zend_if_strlen)
{
/* }}} */
-/* {{{ proto int strcmp(string str1, string str2)
+/* {{{ proto int strcmp(string str1, string str2) U
Binary safe string comparison */
ZEND_FUNCTION(strcmp)
{
/* }}} */
-/* {{{ proto int strncmp(string str1, string str2, int len)
+/* {{{ proto int strncmp(string str1, string str2, int len) U
Binary safe string comparison */
ZEND_FUNCTION(strncmp)
{
/* }}} */
-/* {{{ proto int strcasecmp(string str1, string str2)
+/* {{{ proto int strcasecmp(string str1, string str2) U
Binary safe case-insensitive string comparison */
ZEND_FUNCTION(strcasecmp)
{
/* }}} */
-/* {{{ proto int strncasecmp(string str1, string str2, int len)
+/* {{{ proto int strncasecmp(string str1, string str2, int len) U
Binary safe string comparison */
ZEND_FUNCTION(strncasecmp)
{
/* }}} */
-/* {{{ proto array each(array arr)
+/* {{{ proto array each(array arr) U
Return the currently pointed key..value pair in the passed array, and advance the pointer to the next element */
ZEND_FUNCTION(each)
{
/* }}} */
-/* {{{ proto int error_reporting(int new_error_level=null)
+/* {{{ proto int error_reporting(int new_error_level=null) U
Return the current error_reporting level, and if an argument was passed - change to the new level */
ZEND_FUNCTION(error_reporting)
{
/* }}} */
-/* {{{ proto bool define(string constant_name, mixed value, boolean case_sensitive=true)
+/* {{{ proto bool define(string constant_name, mixed value, boolean case_sensitive=true) U
Define a new constant */
ZEND_FUNCTION(define)
{
/* }}} */
-/* {{{ proto bool defined(string constant_name)
+/* {{{ proto bool defined(string constant_name) U
Check whether a constant exists */
ZEND_FUNCTION(defined)
{
/* }}} */
-/* {{{ proto string get_class([object object])
+/* {{{ proto string get_class([object object]) U
Retrieves the class name */
ZEND_FUNCTION(get_class)
{
/* }}} */
-/* {{{ proto string get_parent_class([mixed object])
+/* {{{ proto string get_parent_class([mixed object]) U
Retrieves the parent class name for object or class or current scope. */
ZEND_FUNCTION(get_parent_class)
{
/* {{{ proto bool is_subclass_of(object object, string class_name)
Returns true if the object has this class as one of its parents */
-ZEND_FUNCTION(is_subclass_of)
+ZEND_FUNCTION(is_subclass_of) U
{
is_a_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 1);
}
/* {{{ proto bool is_a(object object, string class_name)
Returns true if the object is of this class or has this class as one of its parents */
-ZEND_FUNCTION(is_a)
+ZEND_FUNCTION(is_a) U
{
zend_error(E_STRICT, "is_a(): Deprecated. Please use the instanceof operator");
is_a_impl(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0);
zend_hash_move_forward_ex(properties, &pos);
zend_u_unmangle_property_name(key_type, key, &class_name, &prop_name);
if (class_name.v) {
- /* FIXME: Unicode support??? */
+ /* UTODO: Fix this to support Unicode */
if (class_name.s[0] != '*' && strcmp(class_name.s, ce->name.s)) {
/* filter privates from base classes */
continue;
(*value)->refcount++;
add_u_assoc_zval_ex(return_value, UG(unicode)?IS_UNICODE:IS_STRING, key, key_len, *value);
} else if (instanceof) {
+ /* UTODO: Fix this to support Unicode*/
if (class_name.s[0] == '*' ||
(Z_OBJCE_P(EG(This)) == Z_OBJCE_PP(obj) &&
UG(unicode)?!u_strcmp(Z_OBJCE_P(EG(This))->name.u, class_name.u):!strcmp(Z_OBJCE_P(EG(This))->name.s, class_name.s))) {
/* }}} */
-/* {{{ proto array get_class_methods(mixed class)
+/* {{{ proto array get_class_methods(mixed class) U
Returns an array of method names for class or class instance. */
ZEND_FUNCTION(get_class_methods)
{
/* }}} */
-/* {{{ proto bool method_exists(object object, string method)
+/* {{{ proto bool method_exists(object object, string method) U
Checks if the class method exists */
ZEND_FUNCTION(method_exists)
{
RETURN_TRUE;
}
zend_u_unmangle_property_name(Z_TYPE_PP(property), property_info->name, &class_name, &prop_name);
+ /* UTODO: Fix this??? */
if (class_name.s[0] == '*') {
if (instanceof_function(EG(scope), ce TSRMLS_CC)) {
RETURN_TRUE;
/* }}} */
-/* {{{ proto bool class_exists(string classname [, bool autoload])
+/* {{{ proto bool class_exists(string classname [, bool autoload]) U
Checks if the class exists */
ZEND_FUNCTION(class_exists)
{
}
/* }}} */
-/* {{{ proto bool interface_exists(string classname [, bool autoload])
+/* {{{ proto bool interface_exists(string classname [, bool autoload]) U
Checks if the class exists */
ZEND_FUNCTION(interface_exists)
{
/* }}} */
-/* {{{ proto bool function_exists(string function_name)
+/* {{{ proto bool function_exists(string function_name) U
Checks if the function exists */
ZEND_FUNCTION(function_exists)
{
/* }}} */
#if ZEND_DEBUG
-/* {{{ proto void leak(int num_bytes=3)
+/* {{{ proto void leak(int num_bytes=3) U
Cause an intentional memory leak, for testing/debugging purposes */
ZEND_FUNCTION(leak)
{
array_init(return_value);
zend_hash_internal_pointer_reset(&EG(included_files));
while (zend_hash_get_current_key(&EG(included_files), &entry, NULL, 0) == HASH_KEY_IS_STRING) {
+ /* UTODO Not sure this should be runtime encoding.. maybe filename encoding
+ * instead */
add_next_index_rt_string(return_value, entry.s, 1);
zend_hash_move_forward(&EG(included_files));
}
/* }}} */
-/* {{{ proto void trigger_error(string messsage [, int error_type])
+/* {{{ proto void trigger_error(string messsage [, int error_type]) U
Generates a user-level error/warning/notice message */
ZEND_FUNCTION(trigger_error)
{
/* }}} */
-/* {{{ proto string set_error_handler(string error_handler [, int error_types])
+/* {{{ proto string set_error_handler(string error_handler [, int error_types]) U
Sets a user-defined error handler function. Returns the previously defined error handler, or false on error */
ZEND_FUNCTION(set_error_handler)
{
/* }}} */
-/* {{{ proto void restore_error_handler(void)
+/* {{{ proto void restore_error_handler(void) U
Restores the previously defined error handler function */
ZEND_FUNCTION(restore_error_handler)
{
/* }}} */
-/* {{{ proto string set_exception_handler(callable exception_handler)
+/* {{{ proto string set_exception_handler(callable exception_handler) U
Sets a user-defined exception handler function. Returns the previously defined exception handler, or false on error */
ZEND_FUNCTION(set_exception_handler)
{
/* }}} */
-/* {{{ proto void restore_exception_handler(void)
+/* {{{ proto void restore_exception_handler(void) U
Restores the previously defined exception handler function */
ZEND_FUNCTION(restore_exception_handler)
{
}
-/* {{{ proto array get_declared_classes()
+/* {{{ proto array get_declared_classes() U
Returns an array of all declared classes. */
ZEND_FUNCTION(get_declared_classes)
{
}
/* }}} */
-/* {{{ proto array get_declared_interfaces()
+/* {{{ proto array get_declared_interfaces() U
Returns an array of all declared interfaces. */
ZEND_FUNCTION(get_declared_interfaces)
{
}
-/* {{{ proto array get_defined_functions(void)
+/* {{{ proto array get_defined_functions(void) U
Returns an array of all defined functions */
ZEND_FUNCTION(get_defined_functions)
{
/* }}} */
-/* {{{ proto array get_defined_vars(void)
+/* {{{ proto array get_defined_vars(void) U
Returns an associative array of names and values of all currently defined variable names (variables in the current scope) */
ZEND_FUNCTION(get_defined_vars)
{
ZEND_WRONG_PARAM_COUNT();
}
+ /* UTODO: Check whether the following always succeeds */
convert_to_string_ex(z_function_args);
convert_to_string_ex(z_function_code);
#endif
#endif
-/* {{{ proto string get_resource_type(resource res)
+/* {{{ proto string get_resource_type(resource res) U
Get the resource type name for a given resource */
ZEND_FUNCTION(get_resource_type)
{
}
-/* {{{ proto array get_loaded_extensions(void)
+/* {{{ proto array get_loaded_extensions(void) U
Return an array containing names of loaded extensions */
ZEND_FUNCTION(get_loaded_extensions)
{
/* }}} */
-/* {{{ proto array get_defined_constants(void)
+/* {{{ proto array get_defined_constants(void) U
Return an array containing the names and values of all defined constants */
ZEND_FUNCTION(get_defined_constants)
{
}
}
-/* {{{ proto void debug_print_backtrace(void) */
+/* {{{ proto void debug_print_backtrace(void) U */
ZEND_FUNCTION(debug_print_backtrace)
{
zend_execute_data *ptr, *skip;
/* }}} */
-/* {{{ proto array debug_backtrace(void)
+/* {{{ proto array debug_backtrace(void) U
Return backtrace as array */
ZEND_FUNCTION(debug_backtrace)
{
ZEND_WRONG_PARAM_COUNT();
}
+ /* UTODO: using runtime encoding? */
convert_to_string_ex(extension_name);
lcname = zend_str_tolower_dup(Z_STRVAL_PP(extension_name), Z_STRLEN_PP(extension_name));
if (zend_hash_exists(&module_registry, lcname, Z_STRLEN_PP(extension_name)+1)) {
/* }}} */
-/* {{{ proto array get_extension_funcs(string extension_name)
+/* {{{ proto array get_extension_funcs(string extension_name)
Returns an array with the names of functions belonging to the named extension */
ZEND_FUNCTION(get_extension_funcs)
{
ZEND_WRONG_PARAM_COUNT();
}
+ /* UTODO: using runtime encoding? */
convert_to_string_ex(extension_name);
if (strncasecmp(Z_STRVAL_PP(extension_name), "zend", sizeof("zend"))) {
char *lcname = zend_str_tolower_dup(Z_STRVAL_PP(extension_name), Z_STRLEN_PP(extension_name));