mirror of
https://github.com/php/php-src.git
synced 2026-04-21 23:18:13 +02:00
17 lines
373 B
PHP
17 lines
373 B
PHP
--TEST--
|
|
Bug #72122 (IteratorIterator breaks '@' error suppression)
|
|
--FILE--
|
|
<?php
|
|
class CustomIterator implements IteratorAggregate {
|
|
public function getIterator() {
|
|
@unlink('/missing/file.txt');
|
|
return new ArrayIterator(array('item'));
|
|
}
|
|
}
|
|
|
|
$obj = new CustomIterator;
|
|
$iterator = new IteratorIterator($obj);
|
|
echo get_class($iterator);
|
|
?>
|
|
--EXPECT--
|
|
IteratorIterator
|