Skip to content

Latest commit

 

History

History
13 lines (10 loc) · 318 Bytes

InvalidTraversableImplementation.md

File metadata and controls

13 lines (10 loc) · 318 Bytes

InvalidTraversableImplementation

Emitted when class incorrectly implements Traversable. Traversable needs to be implemented by implementing either IteratorAggregate or Iterator

<?php

/**
 * @implements Traversable<mixed, mixed>
 */
final class C implements Traversable {} // will cause fatal error