@@ -12,7 +12,7 @@ var_dump(str_word_count($str));
12
12
var_dump (str_word_count ($ str , 3 ));
13
13
var_dump (str_word_count ($ str , 123 ));
14
14
var_dump (str_word_count ($ str , -1 ));
15
- var_dump (str_word_count ($ str , 99999999999999999 ));
15
+ var_dump (str_word_count ($ str , 999999999 ));
16
16
var_dump (str_word_count ($ str , array ()));
17
17
var_dump (str_word_count ($ str , $ b ));
18
18
var_dump ($ str );
@@ -41,6 +41,8 @@ var_dump(str_word_count("'foo'", 2));
41
41
var_dump (str_word_count ("'foo' " , 2 , "' " ));
42
42
var_dump (str_word_count ("-foo- " , 2 ));
43
43
var_dump (str_word_count ("-foo- " , 2 , "- " ));
44
+
45
+ echo "Done \n" ;
44
46
?>
45
47
--EXPECTF--
46
48
array(6) {
@@ -72,34 +74,34 @@ array(6) {
72
74
string(5) "today"
73
75
}
74
76
int(6)
75
- NULL
76
- NULL
77
- NULL
78
- NULL
79
77
80
- Warning: str_word_count() expects parameter 2 to be long, array given in %s on line 13
78
+ Warning: str_word_count(): Invalid format value 3 in %s on line %d
79
+ bool(false)
81
80
82
- Warning: Wrong parameter count for str_word_count() in %s on line 13
83
- NULL
81
+ Warning: str_word_count(): Invalid format value 123 in %s on line %d
82
+ bool(false)
84
83
85
- Warning: str_word_count() expects parameter 2 to be long, string given in %s on line 14
84
+ Warning: str_word_count(): Invalid format value -1 in %s on line %d
85
+ bool(false)
86
86
87
- Warning: Wrong parameter count for str_word_count() in %s on line 14
87
+ Warning: str_word_count(): Invalid format value 999999999 in %s on line %d
88
+ bool(false)
89
+
90
+ Warning: str_word_count() expects parameter 2 to be long, array given in %s on line %d
91
+ NULL
92
+
93
+ Warning: str_word_count() expects parameter 2 to be long, string given in %s on line %d
88
94
NULL
89
95
string(55) "Hello friend, you're
90
96
looking good today!"
91
97
int(5)
92
98
int(6)
93
99
int(5)
94
100
95
- Warning: str_word_count() expects parameter 3 to be string, array given in %s on line 21
96
-
97
- Warning: Wrong parameter count for str_word_count() in %s on line 21
101
+ Warning: str_word_count() expects parameter 3 to be string, array given in %s on line %d
98
102
NULL
99
103
100
- Warning: str_word_count() expects parameter 3 to be string, object given in %s on line 22
101
-
102
- Warning: Wrong parameter count for str_word_count() in %s on line 22
104
+ Warning: str_word_count() expects parameter 3 to be string, object given in %s on line %d
103
105
NULL
104
106
int(7)
105
107
array(5) {
@@ -141,14 +143,10 @@ array(5) {
141
143
string(3) "foo"
142
144
}
143
145
144
- Warning: str_word_count() expects parameter 3 to be string, array given in %s on line 27
145
-
146
- Warning: Wrong parameter count for str_word_count() in %s on line 27
146
+ Warning: str_word_count() expects parameter 3 to be string, array given in %s on line %d
147
147
NULL
148
148
149
- Warning: str_word_count() expects parameter 3 to be string, object given in %s on line 28
150
-
151
- Warning: Wrong parameter count for str_word_count() in %s on line 28
149
+ Warning: str_word_count() expects parameter 3 to be string, object given in %s on line %d
152
150
NULL
153
151
array(7) {
154
152
[0]=>
@@ -205,14 +203,10 @@ array(5) {
205
203
string(3) "foo"
206
204
}
207
205
208
- Warning: str_word_count() expects parameter 3 to be string, array given in %s on line 33
209
-
210
- Warning: Wrong parameter count for str_word_count() in %s on line 33
206
+ Warning: str_word_count() expects parameter 3 to be string, array given in %s on line %d
211
207
NULL
212
208
213
- Warning: str_word_count() expects parameter 3 to be string, object given in %s on line 34
214
-
215
- Warning: Wrong parameter count for str_word_count() in %s on line 34
209
+ Warning: str_word_count() expects parameter 3 to be string, object given in %s on line %d
216
210
NULL
217
211
array(7) {
218
212
[0]=>
@@ -252,3 +246,4 @@ array(1) {
252
246
[0]=>
253
247
string(5) "-foo-"
254
248
}
249
+ Done
0 commit comments