It occurred to me, while reading different parts of this thread, that if the named parameter feature makes it in to PHP 6.0, there's a solution for both sides of the parameter order argument.

1) yes, would be really nice to clean up the param order for two main reasons: a) constant manual checking b) people whine about param order, incessantly

2) yes, changing this order would break many years of code

Named parameters, no matter what the syntax, as long as it is implemented throughout PHP's function-space, will solve this cleanly:

strpos(needle: $foo, haystack: $bar)
strpos(needle: $bar, haystack: $foo)

This /is/ going to be a headache to implement and document, though.

S

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to