📢 Moderators Needed 🚀

Moderators are needed with resources to post or have access to resources to post. Submit an application to be considered.
X

RSS Functions which use func_get_args should be typehinted with 'mixed ... $arguments'

X

Xon

Guest
Guest or Bot
For example in AbstractCollection::unshift is defined as:

PHP:

Code:
/**
 * @return AbstractCollection<T>
 */
public function unshift()

The phpdocs can be updated to indicate what can be added, like this:
PHP:

Code:
/**
 * @param T ...$arguments
 * @return AbstractCollection<T>
 */
public function unshift()

I've attached a git patch file which implements this (since I'm using this patch locally since I wanted the type hinting)

Continue reading...
 
Similar content Most view View more
Back
Top