@@ -59,7 +59,6 @@ discard block |
||
| 59 | 59 | /** |
| 60 | 60 | * Add a new node in the specified index. |
| 61 | 61 | * |
| 62 | - * @param integer $index the position. |
|
| 63 | 62 | * @param mixed $data the data to be stored. |
| 64 | 63 | */ |
| 65 | 64 | protected function insertEnd($data) { |
@@ -93,7 +92,7 @@ discard block |
||
| 93 | 92 | /** |
| 94 | 93 | * Returns the last node with O(1). |
| 95 | 94 | * |
| 96 | - * @return mixed null if the list is empty. |
|
| 95 | + * @return null|SinglyLinkedListNode null if the list is empty. |
|
| 97 | 96 | */ |
| 98 | 97 | protected function searchLast() { |
| 99 | 98 | if($this->head === null) { |
@@ -243,7 +242,7 @@ discard block |
||
| 243 | 242 | /** |
| 244 | 243 | * Generator for retrieve all nodes stored. |
| 245 | 244 | * |
| 246 | - * @return null if the head is null (or list is empty) |
|
| 245 | + * @return \Generator if the head is null (or list is empty) |
|
| 247 | 246 | */ |
| 248 | 247 | public function getAll() { |
| 249 | 248 | if($this->head === null) { |