Skip to content

Commit 1d794f5

Browse files
committed
Use common function once more
1 parent 0672c9f commit 1d794f5

23 files changed

+100
-100
lines changed

Zend/tests/bug72347.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ function test() : int {
1313
var_dump(test());
1414
?>
1515
--EXPECTF--
16-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
16+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
1717
float(1.5)
1818
int(1)

Zend/tests/float_to_int/union_int_string_type_arg.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ foo(10e500); // Infinity
2121
--EXPECTF--
2222
int(1)
2323

24-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
24+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
2525
int(1)
2626
string(3) "NAN"
2727
string(8) "1.0E+121"

Zend/tests/float_to_int/warnings_float_literals.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -124,16 +124,16 @@ Warning: String offset cast occurred in %s on line %d
124124
string(3) "phz"
125125
Function calls:
126126

127-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
127+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
128128
int(1)
129129

130-
Deprecated: Implicit conversion to int from non-compatible float 60.500000 in %s on line %d
130+
Deprecated: Implicit conversion from non-compatible float 60.5 to int in %s on line %d
131131
string(1) "<"
132132
Function returns:
133133

134-
Deprecated: Implicit conversion to int from non-compatible float 3.500000 in %s on line %d
134+
Deprecated: Implicit conversion from non-compatible float 3.5 to int in %s on line %d
135135
int(3)
136136
Typed property assignment:
137137

138-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
138+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
139139
int(1)

Zend/tests/float_to_int/warnings_float_vars.phpt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -153,16 +153,16 @@ Warning: String offset cast occurred in %s on line %d
153153
string(3) "phz"
154154
Function calls:
155155

156-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
156+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
157157
int(1)
158158

159-
Deprecated: Implicit conversion to int from non-compatible float 60.500000 in %s on line %d
159+
Deprecated: Implicit conversion from non-compatible float 60.5 to int in %s on line %d
160160
string(1) "<"
161161
Function returns:
162162

163-
Deprecated: Implicit conversion to int from non-compatible float 3.500000 in %s on line %d
163+
Deprecated: Implicit conversion from non-compatible float 3.5 to int in %s on line %d
164164
int(3)
165165
Typed property assignment:
166166

167-
Deprecated: Implicit conversion to int from non-compatible float 1.500000 in %s on line %d
167+
Deprecated: Implicit conversion from non-compatible float 1.5 to int in %s on line %d
168168
int(1)

Zend/tests/type_declarations/scalar_basic.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ int(1)
7272
int(1)
7373

7474
*** Trying float(1.5)
75-
E_DEPRECATED: Implicit conversion to int from non-compatible float 1.500000 on line 14
75+
E_DEPRECATED: Implicit conversion from non-compatible float 1.5 to int on line 14
7676
int(1)
7777

7878
*** Trying string(2) "1a"

Zend/tests/type_declarations/scalar_return_basic_64bit.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ int(1)
7171
*** Trying float(1)
7272
int(1)
7373
*** Trying float(1.5)
74-
E_DEPRECATED: Implicit conversion to int from non-compatible float 1.500000 on line 14
74+
E_DEPRECATED: Implicit conversion from non-compatible float 1.5 to int on line 14
7575
int(1)
7676
*** Trying string(2) "1a"
7777
*** Caught {closure}(): Return value must be of type int, string returned in %s on line %d

Zend/zend_API.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -505,7 +505,7 @@ ZEND_API bool ZEND_FASTCALL zend_parse_arg_long_weak(zval *arg, zend_long *dest,
505505
/* Manually check arg_num is not (uint32_t)-1, as otherwise its called by
506506
* zend_verify_weak_scalar_type_hint_no_sideeffect() */
507507
if (UNEXPECTED(!zend_is_long_compatible(Z_DVAL_P(arg), lval) && arg_num != (uint32_t)-1)) {
508-
zend_error(E_DEPRECATED, "Implicit conversion to int from non-compatible float %f", Z_DVAL_P(arg));
508+
zend_incompatible_double_to_long_error(Z_DVAL_P(arg));
509509
if (UNEXPECTED(EG(exception))) {
510510
return 0;
511511
}

ext/standard/tests/array/array_column_basic.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ array(3) {
227227
string(3) "333"
228228
}
229229

230-
Deprecated: Implicit conversion to int from non-compatible float 0.123000 in %s on line %d
230+
Deprecated: Implicit conversion from non-compatible float 0.123 to int in %s on line %d
231231
array(3) {
232232
["aaa"]=>
233233
string(3) "111"
@@ -259,7 +259,7 @@ array(3) {
259259
string(3) "ccc"
260260
}
261261

262-
Deprecated: Implicit conversion to int from non-compatible float 3.140000 in %s on line %d
262+
Deprecated: Implicit conversion from non-compatible float 3.14 to int in %s on line %d
263263
array(0) {
264264
}
265265

ext/standard/tests/array/array_fill.phpt

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ start: 0 num: 1 value: array(1) {
8282
===========================
8383
bool(true)
8484
start: 0 num: 2.5 value:
85-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
85+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
8686
array(2) {
8787
[0]=>
8888
bool(true)
@@ -92,7 +92,7 @@ array(2) {
9292
===========================
9393
bool(false)
9494
start: 0 num: 2.5 value:
95-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
95+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
9696
array(2) {
9797
[0]=>
9898
bool(false)
@@ -102,7 +102,7 @@ array(2) {
102102
===========================
103103
NULL
104104
start: 0 num: 2.5 value:
105-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
105+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
106106
array(2) {
107107
[0]=>
108108
NULL
@@ -112,7 +112,7 @@ array(2) {
112112
===========================
113113
string(1) "d"
114114
start: 0 num: 2.5 value:
115-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
115+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
116116
array(2) {
117117
[0]=>
118118
string(1) "d"
@@ -122,7 +122,7 @@ array(2) {
122122
===========================
123123
string(1) "e"
124124
start: 0 num: 2.5 value:
125-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
125+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
126126
array(2) {
127127
[0]=>
128128
string(1) "e"
@@ -132,7 +132,7 @@ array(2) {
132132
===========================
133133
string(1) "f"
134134
start: 0 num: 2.5 value:
135-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
135+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
136136
array(2) {
137137
[0]=>
138138
string(1) "f"
@@ -202,7 +202,7 @@ start: 1 num: 1 value: array(1) {
202202
===========================
203203
bool(true)
204204
start: 1 num: 2.5 value:
205-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
205+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
206206
array(2) {
207207
[1]=>
208208
bool(true)
@@ -212,7 +212,7 @@ array(2) {
212212
===========================
213213
bool(false)
214214
start: 1 num: 2.5 value:
215-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
215+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
216216
array(2) {
217217
[1]=>
218218
bool(false)
@@ -222,7 +222,7 @@ array(2) {
222222
===========================
223223
NULL
224224
start: 1 num: 2.5 value:
225-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
225+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
226226
array(2) {
227227
[1]=>
228228
NULL
@@ -232,7 +232,7 @@ array(2) {
232232
===========================
233233
string(1) "d"
234234
start: 1 num: 2.5 value:
235-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
235+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
236236
array(2) {
237237
[1]=>
238238
string(1) "d"
@@ -242,7 +242,7 @@ array(2) {
242242
===========================
243243
string(1) "e"
244244
start: 1 num: 2.5 value:
245-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
245+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
246246
array(2) {
247247
[1]=>
248248
string(1) "e"
@@ -252,7 +252,7 @@ array(2) {
252252
===========================
253253
string(1) "f"
254254
start: 1 num: 2.5 value:
255-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
255+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
256256
array(2) {
257257
[1]=>
258258
string(1) "f"
@@ -262,93 +262,93 @@ array(2) {
262262
===========================
263263
bool(true)
264264
start: 2.5 num: 0 value:
265-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
265+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
266266
array(0) {
267267
}
268268
===========================
269269
bool(false)
270270
start: 2.5 num: 0 value:
271-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
271+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
272272
array(0) {
273273
}
274274
===========================
275275
NULL
276276
start: 2.5 num: 0 value:
277-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
277+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
278278
array(0) {
279279
}
280280
===========================
281281
string(1) "d"
282282
start: 2.5 num: 0 value:
283-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
283+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
284284
array(0) {
285285
}
286286
===========================
287287
string(1) "e"
288288
start: 2.5 num: 0 value:
289-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
289+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
290290
array(0) {
291291
}
292292
===========================
293293
string(1) "f"
294294
start: 2.5 num: 0 value:
295-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
295+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
296296
array(0) {
297297
}
298298
===========================
299299
bool(true)
300300
start: 2.5 num: 1 value:
301-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
301+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
302302
array(1) {
303303
[2]=>
304304
bool(true)
305305
}
306306
===========================
307307
bool(false)
308308
start: 2.5 num: 1 value:
309-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
309+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
310310
array(1) {
311311
[2]=>
312312
bool(false)
313313
}
314314
===========================
315315
NULL
316316
start: 2.5 num: 1 value:
317-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
317+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
318318
array(1) {
319319
[2]=>
320320
NULL
321321
}
322322
===========================
323323
string(1) "d"
324324
start: 2.5 num: 1 value:
325-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
325+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
326326
array(1) {
327327
[2]=>
328328
string(1) "d"
329329
}
330330
===========================
331331
string(1) "e"
332332
start: 2.5 num: 1 value:
333-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
333+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
334334
array(1) {
335335
[2]=>
336336
string(1) "e"
337337
}
338338
===========================
339339
string(1) "f"
340340
start: 2.5 num: 1 value:
341-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
341+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
342342
array(1) {
343343
[2]=>
344344
string(1) "f"
345345
}
346346
===========================
347347
bool(true)
348348
start: 2.5 num: 2.5 value:
349-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
349+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
350350

351-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
351+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
352352
array(2) {
353353
[2]=>
354354
bool(true)
@@ -358,9 +358,9 @@ array(2) {
358358
===========================
359359
bool(false)
360360
start: 2.5 num: 2.5 value:
361-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
361+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
362362

363-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
363+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
364364
array(2) {
365365
[2]=>
366366
bool(false)
@@ -370,9 +370,9 @@ array(2) {
370370
===========================
371371
NULL
372372
start: 2.5 num: 2.5 value:
373-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
373+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
374374

375-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
375+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
376376
array(2) {
377377
[2]=>
378378
NULL
@@ -382,9 +382,9 @@ array(2) {
382382
===========================
383383
string(1) "d"
384384
start: 2.5 num: 2.5 value:
385-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
385+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
386386

387-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
387+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
388388
array(2) {
389389
[2]=>
390390
string(1) "d"
@@ -394,9 +394,9 @@ array(2) {
394394
===========================
395395
string(1) "e"
396396
start: 2.5 num: 2.5 value:
397-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
397+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
398398

399-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
399+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
400400
array(2) {
401401
[2]=>
402402
string(1) "e"
@@ -406,9 +406,9 @@ array(2) {
406406
===========================
407407
string(1) "f"
408408
start: 2.5 num: 2.5 value:
409-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
409+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
410410

411-
Deprecated: Implicit conversion to int from non-compatible float 2.500000 in %s on line %d
411+
Deprecated: Implicit conversion from non-compatible float 2.5 to int in %s on line %d
412412
array(2) {
413413
[2]=>
414414
string(1) "f"

ext/standard/tests/file/disk_free_space_basic.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ float(%f)
6161
float(%f)
6262

6363
Free Space Value Is Incorrect
64-
float(894625087488)
65-
float(894625087488)
64+
float(892086792192)
65+
float(892086792192)
6666
*** Testing with Binary Input ***
6767
float(%f)
6868

0 commit comments

Comments
 (0)