Skip to content

Commit 449812c

Browse files
authored
Update phpdoc-types.md
1 parent 75f18eb commit 449812c

File tree

1 file changed

+0
-18
lines changed

1 file changed

+0
-18
lines changed

website/src/writing-php-code/phpdoc-types.md

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -86,24 +86,6 @@ This is useful if we want to tell that a method from a parent class will return
8686

8787
A narrower `@return $this` instead of `@return static` can also be used, and PHPStan will check if you're really returning the same object instance and not just an object of the child class.
8888

89-
Variadic functions
90-
-------------------------
91-
92-
This allows specifying functions or methods which have a variable amount of parameters (available since [PHP 5.6](https://www.php.net/manual/en/migration56.new-features.php)).
93-
94-
Your code can look like this:
95-
96-
```php
97-
/**
98-
* @param string $arg
99-
* @param string ...$additional
100-
*/
101-
function foo($arg, ...$additional)
102-
{
103-
104-
}
105-
```
106-
10789
Generics
10890
-------------------------
10991

0 commit comments

Comments
 (0)