Doc #80570 [Opn->Ver]: Incorrect named argument name for the nested function
Edit report at https://bugs.php.net/bug.php?id=80570&edit=1
ID: 80570
Updated by: requinix@php.net
Reported by: vasilii dot b dot shpilchin at gmail dot com
Summary: Incorrect named argument name for the nested
function
-Status: Open
+Status: Verified
Type: Documentation Problem
-Package: Documentation problem
+Package: *General Issues
PHP Version: 8.0.0
Block user comment: N
Private report: N
New Comment:
Related to bug #80477
Previous Comments:
------------------------------------------------------------------------
[2020-12-31 22:24:50] vasilii dot b dot shpilchin at gmail dot com
Description:
------------
---
From manual page: https://php.net/functions.arguments
---
Named arguments Example #14 got the error: "Unknown named parameter $num".
Instead of this:
array_fill(start_index: 0, num: 100, value: 50);
it should be this:
array_fill(start_index: 0, count: 100, value: 50);
Thank you!
Test script:
---------------
// Run this, see error then comment out the first call and run again
var_dump(array_fill(start_index: 0, num: 100, value: 50));
var_dump(array_fill(start_index: 0, count: 100, value: 50));
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=80570&edit=1
Thread (3 messages)