From c57b7cee886533dfe4c60676a448c57b422c69ed Mon Sep 17 00:00:00 2001 From: Cees-Jan Kiewiet Date: Sun, 17 Jul 2022 19:14:38 +0200 Subject: [PATCH] Ensure lowest PHPStan understands current and key have return types --- src/AwaitingIterator.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/AwaitingIterator.php b/src/AwaitingIterator.php index c338cd7..730dea9 100644 --- a/src/AwaitingIterator.php +++ b/src/AwaitingIterator.php @@ -67,20 +67,30 @@ private function complete(): void $valid->resolve(false); } + // phpcs:disable + /** + * @return mixed + */ public function current(): mixed { return $this->queue->dequeue(); } + // phpcs:enable public function next(): void { // no-op } + // phpcs:disable + /** + * @return mixed + */ public function key(): mixed { return $this->key++; } + // phpcs:enable /** * @psalm-suppress MixedInferredReturnType