Skip to content

Commit 25f1c40

Browse files
committed
Update ext/standard parameter names
Closes GH-6214.
1 parent 1945355 commit 25f1c40

File tree

95 files changed

+5952
-5967
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+5952
-5967
lines changed

Zend/tests/bug75290.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ var_dump(function ($someThing) {});
1212
object(Closure)#2 (1) {
1313
["parameter"]=>
1414
array(1) {
15-
["$number"]=>
15+
["$num"]=>
1616
string(10) "<required>"
1717
}
1818
}

Zend/tests/bug79783.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Bug #79783: Segfault in php_str_replace_common
55
str_replace("a", "b", "c", strlen("d"));
66
?>
77
--EXPECTF--
8-
Fatal error: Uncaught Error: str_replace(): Argument #4 ($replace_count) cannot be passed by reference in %s:%d
8+
Fatal error: Uncaught Error: str_replace(): Argument #4 ($count) cannot be passed by reference in %s:%d
99
Stack trace:
1010
#0 {main}
1111
thrown in %s on line %d

Zend/tests/bug79979.phpt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,17 @@ Bug #79979 (passing value to by-ref param via CUF(A) crashes)
66
namespace Foo;
77

88
call_user_func_array("str_replace", ["a", "b", "c", new \stdClass]);
9-
call_user_func_array("str_replace", ["a", "b", "c", "replace_count" => new \stdClass]);
9+
call_user_func_array("str_replace", ["a", "b", "c", "count" => new \stdClass]);
1010

1111
\call_user_func_array("str_replace", ["a", "b", "c", new \stdClass]);
12-
\call_user_func_array("str_replace", ["a", "b", "c", "replace_count" => new \stdClass]);
12+
\call_user_func_array("str_replace", ["a", "b", "c", "count" => new \stdClass]);
1313

1414
?>
1515
--EXPECTF--
16-
Warning: str_replace(): Argument #4 ($replace_count) must be passed by reference, value given in %s on line %d
16+
Warning: str_replace(): Argument #4 ($count) must be passed by reference, value given in %s on line %d
1717

18-
Warning: str_replace(): Argument #4 ($replace_count) must be passed by reference, value given in %s on line %d
18+
Warning: str_replace(): Argument #4 ($count) must be passed by reference, value given in %s on line %d
1919

20-
Warning: str_replace(): Argument #4 ($replace_count) must be passed by reference, value given in %s on line %d
20+
Warning: str_replace(): Argument #4 ($count) must be passed by reference, value given in %s on line %d
2121

22-
Warning: str_replace(): Argument #4 ($replace_count) must be passed by reference, value given in %s on line %d
22+
Warning: str_replace(): Argument #4 ($count) must be passed by reference, value given in %s on line %d

Zend/tests/call_user_func_001.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,5 +37,5 @@ namespace testing {
3737
?>
3838
--EXPECT--
3939
string(6) "foobar"
40-
call_user_func(): Argument #1 ($function) must be a valid callback, cannot access private method testing\foo::priv()
41-
call_user_func(): Argument #1 ($function) must be a valid callback, cannot access protected method testing\foo::prot()
40+
call_user_func(): Argument #1 ($callback) must be a valid callback, cannot access private method testing\foo::priv()
41+
call_user_func(): Argument #1 ($callback) must be a valid callback, cannot access protected method testing\foo::prot()

ext/date/tests/microtime_error.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@ float(%s)
4646
int(0)
4747
}
4848
}
49-
microtime(): Argument #1 ($getAsFloat) must be of type bool, array given
49+
microtime(): Argument #1 ($as_float) must be of type bool, array given
5050

5151
--> bad arg: object(stdClass)#%d (0) {
5252
}
53-
microtime(): Argument #1 ($getAsFloat) must be of type bool, stdClass given
53+
microtime(): Argument #1 ($as_float) must be of type bool, stdClass given
5454

5555
--> bad arg: int(1)
5656
float(%s)

ext/phar/tests/fgc_edgecases.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ echo file_get_contents("./hi", 0, $context, 50000);
7171
echo file_get_contents("./hi");
7272
echo file_get_contents("./hi", 0, $context, 0, 0);
7373
?>
74-
file_get_contents(): Argument #5 ($maxlen) must be greater than or equal to 0
74+
file_get_contents(): Argument #5 ($max_length) must be greater than or equal to 0
7575
test
7676
test
7777
<?php

ext/phar/tests/opendir_edgecases.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ include $pname . '/foo';
5555
<?php unlink(__DIR__ . '/' . basename(__FILE__, '.clean.php') . '.phar.php'); ?>
5656
<?php rmdir(__DIR__ . '/opendir_edgecases');
5757
--EXPECTF--
58-
opendir(): Argument #1 ($path) must be of type string, array given
58+
opendir(): Argument #1 ($directory) must be of type string, array given
5959
.
6060
..
6161
foo

ext/reflection/tests/ReflectionParameter_canBePassedByValue.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ echo "Done.\n";
3737
--EXPECT--
3838
=> array_multisort:
3939

40-
Name: array1
40+
Name: array
4141
Is passed by reference: yes
4242
Can be passed by value: yes
4343

0 commit comments

Comments
 (0)