Re: [RFC] Named parameters

From: Date: Fri, 06 Sep 2013 17:01:46 +0000
Subject: Re: [RFC] Named parameters
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-68911@lists.php.net to get a copy of this message
Le 06/09/2013 18:39, Nikita Popov a écrit :
Hi internals! I created an RFC and preliminary implementation for named parameters:
     https://wiki.php.net/rfc/named_params
The RFC and implementation are not yet complete. I mainly want to have feedback on the idea in general and on the Open Questions ( https://wiki.php.net/rfc/named_params#open_questions) in particular. Thanks, Nikita
Hi Nikita, I love it and I love that it also applies to internal functions! My preference for syntax would be this one: test($foo: "oof", $bar: "rab"); Using the $ sign means that it doesn't class with reserved keywords and that is consistent with the use of the dollar sign in PHP when we define the functions. I prefer : to => because it is a tad shorter and I think a bit more readable. Thanks! Pascal

« previous php.internals (#68911) next »