ZF-10583: Unhelpful exception message thrown when docblock params do not match actual function params
When implementing a server (in our case using Zend_AMF), if the number of parameters listed in the docblock (@param) of your class methods do not match the number of parameters in the actual function definition, then the following exception is thrown:
bq. Variable number of arguments is not supported for services (except optional parameters). Number of function arguments must correspond to actual number of arguments described in a docblock.
This exception is thrown from line 340 (revision 23180) of library/Zend/Server/Reflection/Function/Abstract.php.
In short, it took me quite a while to find the actual offending class and method that was generating this exception. This is because the exception message is unhelpful. I have created a patch to make this a more helpful message. I'm attaching the patch to this issue.