diff options
author | Gabriel Caruso <carusogabriel34@gmail.com> | 2018-02-04 11:33:49 -0200 |
---|---|---|
committer | Nikita Popov <nikita.ppv@gmail.com> | 2018-02-04 19:08:23 +0100 |
commit | ce1d69a1f6dcf15d43029301059c25e5bc09a577 (patch) | |
tree | 3df785771b4bfa07a9e270b04750840ed47f1cbf /Zend/zend_API.c | |
parent | 4861730a945908208a049b0c037ddf4a339f999a (diff) | |
download | php-git-ce1d69a1f6dcf15d43029301059c25e5bc09a577.tar.gz |
Use int instead of integer in type errors
PHP requires integer typehints to be written "int" and does not
allow "integer" as an alias. This changes type error messages to
match the actual type name and avoids confusing messages like
"must be of the type integer, integer given".
Diffstat (limited to 'Zend/zend_API.c')
-rw-r--r-- | Zend/zend_API.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 79d6ab9a6c..d0ab8a31ec 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -107,7 +107,7 @@ ZEND_API char *zend_get_type_by_const(int type) /* {{{ */ case _IS_BOOL: return "boolean"; case IS_LONG: - return "integer"; + return "int"; case IS_DOUBLE: return "float"; case IS_STRING: @@ -497,7 +497,7 @@ static const char *zend_parse_arg_impl(int arg_num, zval *arg, va_list *va, cons } if (!zend_parse_arg_long(arg, p, is_null, check_null, c == 'L')) { - return "integer"; + return "int"; } } break; |