diff options
author | Nikita Popov <nikic@php.net> | 2015-03-15 09:47:25 +0100 |
---|---|---|
committer | Nikita Popov <nikic@php.net> | 2015-04-01 11:17:55 +0200 |
commit | 8d00385871c6dca1f18a5e7924c655a2cb381564 (patch) | |
tree | aeaa0503ba613bc77332dde492b71f6f105d0ef2 /Zend/zend_API.c | |
parent | 4796e0242b8cdd2a77b552fcbaa74d70d87f6d0a (diff) | |
download | php-git-8d00385871c6dca1f18a5e7924c655a2cb381564.tar.gz |
Reclassify E_STRICT notices
Per RFC https://wiki.php.net/rfc/reclassify_e_strict
While reviewing this, found that there are still three E_STRICTs
left in libraries - need to discuss those.
Diffstat (limited to 'Zend/zend_API.c')
-rw-r--r-- | Zend/zend_API.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 4295159c7b..5a01d546ab 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -710,7 +710,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval *arg, va_list *va, cons if (zend_fcall_info_init(arg, 0, fci, fcc, NULL, &is_callable_error) == SUCCESS) { if (is_callable_error) { - *severity = E_STRICT; + *severity = E_DEPRECATED; zend_spprintf(error, 0, "to be a valid callback, %s", is_callable_error); efree(is_callable_error); *spec = spec_walk; @@ -772,7 +772,7 @@ static int zend_parse_arg(int arg_num, zval *arg, va_list *va, const char **spec zend_zval_type_name(arg)); } } - if (severity != E_STRICT) { + if (severity != E_DEPRECATED) { return FAILURE; } } @@ -1638,7 +1638,7 @@ ZEND_API int array_set_zval_key(HashTable *ht, zval *key, zval *value) /* {{{ */ result = zend_symtable_update(ht, STR_EMPTY_ALLOC(), value); break; case IS_RESOURCE: - zend_error(E_STRICT, "Resource ID#" ZEND_LONG_FMT " used as offset, casting to integer (%pd)", Z_RES_HANDLE_P(key), Z_RES_HANDLE_P(key)); + zend_error(E_NOTICE, "Resource ID#" ZEND_LONG_FMT " used as offset, casting to integer (%pd)", Z_RES_HANDLE_P(key), Z_RES_HANDLE_P(key)); result = zend_hash_index_update(ht, Z_RES_HANDLE_P(key), value); break; case IS_FALSE: @@ -3098,7 +3098,7 @@ get_function_via_handler: int severity; char *verb; if (fcc->function_handler->common.fn_flags & ZEND_ACC_ALLOW_STATIC) { - severity = E_STRICT; + severity = E_DEPRECATED; verb = "should not"; } else { /* An internal function assumes $this is present and won't check that. So PHP would crash by allowing the call. */ |