ID: 13892
Updated by: sander
Reported By: [EMAIL PROTECTED]
Status: Open
Bug Type: Feature/Change Request
Operating System: any
PHP Version: 4.0.6
New Comment:

Changing this would break a lot of scripts.
And what's wrong with specifying too many parameters? If you don't use them 
explicitly, they don't influence the function, so why care about them?

Previous Comments:
------------------------------------------------------------------------

[2001-10-31 19:09:46] [EMAIL PROTECTED]

Currently, it seems PHP is designed NOT to report errors for too many paramaters for 
user defined functions.

"..." for variable length paramters. Raise error without "...", for example.

function foo($var1, $var2, ...)

assert(count(function_get_args()) <= 3);
or like can be used to check num of paramters, but module functions checks num of 
parameters. User functions are better to behave the same way by default. IMHO.

------------------------------------------------------------------------



Edit this bug report at http://bugs.php.net/?id=13892&edit=1


-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to