Skip to content

Commit d59eced

Browse files
committed
Fix messages
1 parent e8e1ccd commit d59eced

File tree

4 files changed

+9
-9
lines changed

4 files changed

+9
-9
lines changed

ext/standard/array.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6291,7 +6291,7 @@ PHP_FUNCTION(array_key_exists)
62916291
RETVAL_BOOL(zend_hash_index_exists(ht, Z_RES_HANDLE_P(key)));
62926292
break;
62936293
default:
6294-
zend_argument_type_error(1, "to be a valid array offset type");
6294+
zend_argument_type_error(1, "must be a valid array offset type");
62956295
break;
62966296
}
62976297
}

ext/standard/streamsfuncs.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -968,7 +968,7 @@ PHP_FUNCTION(stream_context_get_options)
968968

969969
context = decode_context_param(zcontext);
970970
if (!context) {
971-
zend_argument_type_error(1, "to be a valid stream/context");
971+
zend_argument_type_error(1, "must be a valid stream/context");
972972
RETURN_THROWS();
973973
}
974974

@@ -993,7 +993,7 @@ PHP_FUNCTION(stream_context_set_option)
993993

994994
/* figure out where the context is coming from exactly */
995995
if (!(context = decode_context_param(zcontext))) {
996-
zend_argument_type_error(1, "to be a valid stream/context");
996+
zend_argument_type_error(1, "must be a valid stream/context");
997997
RETURN_THROWS();
998998
}
999999

@@ -1012,7 +1012,7 @@ PHP_FUNCTION(stream_context_set_option)
10121012

10131013
/* figure out where the context is coming from exactly */
10141014
if (!(context = decode_context_param(zcontext))) {
1015-
zend_argument_type_error(1, "to be a valid stream/context");
1015+
zend_argument_type_error(1, "must be a valid stream/context");
10161016
RETURN_THROWS();
10171017
}
10181018

@@ -1035,7 +1035,7 @@ PHP_FUNCTION(stream_context_set_params)
10351035

10361036
context = decode_context_param(zcontext);
10371037
if (!context) {
1038-
zend_argument_type_error(1, "to be a valid stream/context");
1038+
zend_argument_type_error(1, "must be a valid stream/context");
10391039
RETURN_THROWS();
10401040
}
10411041

@@ -1056,7 +1056,7 @@ PHP_FUNCTION(stream_context_get_params)
10561056

10571057
context = decode_context_param(zcontext);
10581058
if (!context) {
1059-
zend_argument_type_error(1, "to be a valid stream/context");
1059+
zend_argument_type_error(1, "must be a valid stream/context");
10601060
RETURN_THROWS();
10611061
}
10621062

ext/standard/string.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5594,7 +5594,7 @@ PHP_FUNCTION(str_pad)
55945594
}
55955595

55965596
if (pad_str_len == 0) {
5597-
zend_argument_value_error(3, "must be non-empty string");
5597+
zend_argument_value_error(3, "must be a non-empty string");
55985598
RETURN_THROWS();
55995599
}
56005600

ext/standard/tests/strings/str_pad.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -339,6 +339,6 @@ string(16) "\t\variation\t\t"
339339
#### error conditions ####
340340

341341
--- padding string as null ---
342-
str_pad(): Argument #3 ($pad_string) must be non-empty string
343-
str_pad(): Argument #3 ($pad_string) must be non-empty string
342+
str_pad(): Argument #3 ($pad_string) must be a non-empty string
343+
str_pad(): Argument #3 ($pad_string) must be a non-empty string
344344
str_pad(): Argument #4 ($pad_type) must be STR_PAD_LEFT, STR_PAD_RIGHT, or STR_PAD_BOTH

0 commit comments

Comments
 (0)