8000 Fix deprecated warning in new gh8289.phpt test · php/php-src@e4c7ffc · GitHub
[go: up one dir, main page]

Skip to content

Commit e4c7ffc

Browse files
committed
Fix deprecated warning in new gh8289.phpt test
1 parent 16dcede commit e4c7ffc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Zend/tests/generators/gh8289.phpt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ GH-8289 (Exceptions thrown within a yielded from iterator are not rethrown into
66
function yieldFromIteratorGeneratorThrows() {
77
try {
88
yield from new class(new ArrayIterator([1, -2])) extends IteratorIterator {
9-
public function key() {
9+
public function key(): mixed {
1010
if ($k = parent::key()) {
1111
throw new Exception;
1212
}
@@ -31,4 +31,4 @@ Stack trace:
3131
#0 %s(%d): IteratorIterator@anonymous->key()
3232
#1 %s(%d): yieldFromIteratorGeneratorThrows()
3333
#2 {main}
34-
int(2)
34+
int(2)

0 commit comments

Comments
 (0)
0