]> granicus.if.org Git - php/commitdiff
Remove unnecessary uses of CHECK_SILENT
authorNikita Popov <nikita.ppv@gmail.com>
Fri, 6 Mar 2020 15:34:15 +0000 (16:34 +0100)
committerNikita Popov <nikita.ppv@gmail.com>
Fri, 6 Mar 2020 15:36:45 +0000 (16:36 +0100)
If no error is passed, it is always silent.

Zend/zend_execute.c
ext/opcache/jit/zend_jit_helpers.c
main/streams/userspace.c

index f550614130d35631a18b5a8200e67ec8645a620e..6f6fb59ecab88c7b82192eac8f90f4cc3ed358b6 100644 (file)
@@ -1011,7 +1011,7 @@ static zend_always_inline zend_bool zend_check_type_slow(
 
 builtin_types:
        type_mask = ZEND_TYPE_FULL_MASK(type);
-       if ((type_mask & MAY_BE_CALLABLE) && zend_is_callable(arg, IS_CALLABLE_CHECK_SILENT, NULL)) {
+       if ((type_mask & MAY_BE_CALLABLE) && zend_is_callable(arg, 0, NULL)) {
                return 1;
        }
        if ((type_mask & MAY_BE_ITERABLE) && zend_is_iterable(arg)) {
index 7fd91c7317d4b254f295ed810db2b0eac4eec06b..40d10e4255ebdef23c4eedee429ec780a0b7cc4a 100644 (file)
@@ -1184,7 +1184,7 @@ static zend_always_inline zend_bool zend_jit_verify_type_common(zval *arg, const
 
 builtin_types:
        type_mask = ZEND_TYPE_FULL_MASK(arg_info->type);
-       if ((type_mask & MAY_BE_CALLABLE) && zend_is_callable(arg, IS_CALLABLE_CHECK_SILENT, NULL)) {
+       if ((type_mask & MAY_BE_CALLABLE) && zend_is_callable(arg, 0, NULL)) {
                return 1;
        }
        if ((type_mask & MAY_BE_ITERABLE) && zend_is_iterable(arg)) {
index dd6806d35f69c2c4408ae1b885dc260144e75356..ffdd0754e4f0ee708b3d278c0d9079f9aabe92b5 100644 (file)
@@ -1000,7 +1000,7 @@ static int php_userstreamop_set_option(php_stream *stream, int option, int value
                case PHP_STREAM_TRUNCATE_SUPPORTED:
                        if (zend_is_callable_ex(&func_name,
                                        Z_ISUNDEF(us->object)? NULL : Z_OBJ(us->object),
-                                       IS_CALLABLE_CHECK_SILENT, NULL, NULL, NULL))
+                                       0, NULL, NULL, NULL))
                                ret = PHP_STREAM_OPTION_RETURN_OK;
                        else
                                ret = PHP_STREAM_OPTION_RETURN_ERR;