On 21/01/2017 17:42, Christoph M. Becker wrote:
In the long run (i.e. for PHP 8) I'd suggest to purge the $num_points parameter altogether, relying solely on the number of $points given.
Since there's a 4th parameter ($color), what would "purge" mean in this case? Reducing the number of parameters to 3 would be very confusing, because existing code passing $num_points would be interpreted as passing that value as $color.
We could ignore the argument whatever value was provided; or we could document that it should be passed as null, and raise a warning if it's anything else; or we could ignore it if it matched the length of $points, and raise a warning or error if it didn't...
Regards, -- Rowan Collins [IMSoP] -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php