com php-src: Correct type hint name for booleans in method signatures: Zend/zend_inheritance.c
| From: | Bob Weinand | Date: | Thu, 02 Jul 2015 19:14:30 +0000 |
| Subject: | com php-src: Correct type hint name for booleans in method signatures: Zend/zend_inheritance.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87711@lists.php.net to get a copy of this message | ||
Commit: 5f72d94a8b4f4c070fd4959114f27448074a4a9e
Author: Niklas Keller <me@kelunik.com> Thu, 2 Jul 2015 20:34:49 +0200
Committer: Bob Weinand <bobwei9@hotmail.com> Thu, 2 Jul 2015 21:14:30 +0200
Parents: 6ff72467dc2595183ef31b30b4d4195f65a78f57
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=5f72d94a8b4f4c070fd4959114f27448074a4a9e
Log:
Correct type hint name for booleans in method signatures
Changed paths:
M Zend/zend_inheritance.c
Diff:
diff --git a/Zend/zend_inheritance.c b/Zend/zend_inheritance.c
index f1a6d60..64e7407 100644
--- a/Zend/zend_inheritance.c
+++ b/Zend/zend_inheritance.c
@@ -178,7 +178,7 @@ static int zend_do_perform_type_hint_check(const zend_function *fe, zend_arg_inf
zend_string *fe_class_name, *proto_class_name;
const char *class_name;
- if (fe->type == ZEND_INTERNAL_FUNCTION) {
+ if (fe->type == ZEND_INTERNAL_FUNCTION) {
fe_class_name = NULL;
class_name = ((zend_internal_arg_info*)fe_arg_info)->class_name;
} else {
@@ -195,7 +195,7 @@ static int zend_do_perform_type_hint_check(const zend_function *fe, zend_arg_inf
fe_class_name = zend_string_init(class_name, strlen(class_name), 0);
}
- if (proto->type == ZEND_INTERNAL_FUNCTION) {
+ if (proto->type == ZEND_INTERNAL_FUNCTION) {
proto_class_name = NULL;
class_name = ((zend_internal_arg_info*)proto_arg_info)->class_name;
} else {
@@ -374,6 +374,8 @@ static void zend_append_type_hint(smart_str *str, const zend_function *fptr, zen
} else if (arg_info->type_hint) {
if (arg_info->type_hint == IS_LONG) {
smart_str_appendl(str, "int", 3);
+ } else if (arg_info->type_hint == _IS_BOOL) {
+ smart_str_appendl(str, "bool", 4);
} else {
const char *type_name = zend_get_type_by_const(arg_info->type_hint);
smart_str_appends(str, type_name);