Does the order of named arguments matter in PHP8

Viewed 33

Since PHP 8 you can use named arguments in PHP functions like:

function fn($a, $b) {}

fn(b: "b", a: "a");

But when changing order of parameters PhpStorm gives me wrong parameter order warning:

Named arguments order does not match parameters order 

Is there any reason to maintain order in parameters or is it just a weird default setting?

Whats the purpose of using named parameters if you have to maintain the order?

0 Answers
Related