Skip to content

Commit

Permalink
Add explicit @return type next to #[ReturnTypeWillChange] (#280)
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-grekas authored Aug 10, 2021
1 parent a382560 commit 1958a74
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/Doctrine/Common/Collections/AbstractLazyCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,8 @@ public function offsetGet($offset)
*
* @param mixed $value
* @psalm-param TKey $offset
*
* @return void
*/
#[ReturnTypeWillChange]
public function offsetSet($offset, $value)
Expand All @@ -339,6 +341,8 @@ public function offsetSet($offset, $value)
* {@inheritDoc}
*
* @psalm-param TKey $offset
*
* @return void
*/
#[ReturnTypeWillChange]
public function offsetUnset($offset)
Expand Down
6 changes: 6 additions & 0 deletions lib/Doctrine/Common/Collections/ArrayCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,8 @@ public function offsetExists($offset)
* {@inheritDoc}
*
* @psalm-param TKey $offset
*
* @return mixed
*/
#[ReturnTypeWillChange]
public function offsetGet($offset)
Expand All @@ -194,6 +196,8 @@ public function offsetGet($offset)
* Required by interface ArrayAccess.
*
* {@inheritDoc}
*
* @return void
*/
#[ReturnTypeWillChange]
public function offsetSet($offset, $value)
Expand All @@ -213,6 +217,8 @@ public function offsetSet($offset, $value)
* {@inheritDoc}
*
* @psalm-param TKey $offset
*
* @return void
*/
#[ReturnTypeWillChange]
public function offsetUnset($offset)
Expand Down

0 comments on commit 1958a74

Please sign in to comment.