diff options
author | Hannes Magnusson <bjori@php.net> | 2006-07-07 11:55:23 +0000 |
---|---|---|
committer | Hannes Magnusson <bjori@php.net> | 2006-07-07 11:55:23 +0000 |
commit | 147840dd93d3209416230071c63ae98e07471bac (patch) | |
tree | 395299baa8f24c5ff2520802c1616a23e2ef40e7 /ext/reflection/php_reflection.c | |
parent | 89635eb158b68e8daf77e2f49aa6fa233f112cd0 (diff) | |
download | php-git-147840dd93d3209416230071c63ae98e07471bac.tar.gz |
MFH: ReflectionFunction::isDisabled()
Diffstat (limited to 'ext/reflection/php_reflection.c')
-rw-r--r-- | ext/reflection/php_reflection.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 7fb0eec78d..f1ab8560bf 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -1414,6 +1414,19 @@ ZEND_METHOD(reflection_function, isUserDefined) } /* }}} */ +/* {{{ proto public bool ReflectionFunction::isDisabled() + Returns whether this function has been disabled or not */ +ZEND_METHOD(reflection_function, isDisabled) +{ + reflection_object *intern; + zend_function *fptr; + + METHOD_NOTSTATIC(reflection_function_ptr); + GET_REFLECTION_OBJECT_PTR(fptr); + RETURN_BOOL(fptr->type == ZEND_INTERNAL_FUNCTION && fptr->internal_function.handler == zif_display_disabled_function); +} +/* }}} */ + /* {{{ proto public string ReflectionFunction::getFileName() Returns the filename of the file this function was declared in */ ZEND_METHOD(reflection_function, getFileName) @@ -4328,6 +4341,7 @@ static zend_function_entry reflection_function_abstract_functions[] = { static zend_function_entry reflection_function_functions[] = { ZEND_ME(reflection_function, export, arginfo_reflection_function_export, ZEND_ACC_STATIC|ZEND_ACC_PUBLIC) + ZEND_ME(reflection_function, isDisabled, NULL, 0) ZEND_ME(reflection_function, invoke, arginfo_reflection_function_invoke, 0) ZEND_ME(reflection_function, invokeArgs, arginfo_reflection_function_invokeArgs, 0) {NULL, NULL, NULL} |