summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Zend/zend_reflection_api.c8
-rw-r--r--ext/reflection/php_reflection.c8
2 files changed, 14 insertions, 2 deletions
diff --git a/Zend/zend_reflection_api.c b/Zend/zend_reflection_api.c
index 56af747dee..58f763b8aa 100644
--- a/Zend/zend_reflection_api.c
+++ b/Zend/zend_reflection_api.c
@@ -563,7 +563,13 @@ static void _parameter_string(string *str, zend_function *fptr, struct _zend_arg
zv_copy = precv->op2.u.constant;
zv = &zv_copy;
zval_update_constant(&zv, (void*)1 TSRMLS_CC);
- if (Z_TYPE_P(zv) == IS_NULL) {
+ if (Z_TYPE_P(zv) == IS_BOOL) {
+ if (Z_LVAL_P(zv)) {
+ string_write(str, "true", sizeof("true")-1);
+ } else {
+ string_write(str, "false", sizeof("false")-1);
+ }
+ } else if (Z_TYPE_P(zv) == IS_NULL) {
string_write(str, "NULL", sizeof("NULL")-1);
} else if (Z_TYPE_P(zv) == IS_STRING) {
string_write(str, "'", sizeof("'")-1);
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c
index 56af747dee..58f763b8aa 100644
--- a/ext/reflection/php_reflection.c
+++ b/ext/reflection/php_reflection.c
@@ -563,7 +563,13 @@ static void _parameter_string(string *str, zend_function *fptr, struct _zend_arg
zv_copy = precv->op2.u.constant;
zv = &zv_copy;
zval_update_constant(&zv, (void*)1 TSRMLS_CC);
- if (Z_TYPE_P(zv) == IS_NULL) {
+ if (Z_TYPE_P(zv) == IS_BOOL) {
+ if (Z_LVAL_P(zv)) {
+ string_write(str, "true", sizeof("true")-1);
+ } else {
+ string_write(str, "false", sizeof("false")-1);
+ }
+ } else if (Z_TYPE_P(zv) == IS_NULL) {
string_write(str, "NULL", sizeof("NULL")-1);
} else if (Z_TYPE_P(zv) == IS_STRING) {
string_write(str, "'", sizeof("'")-1);