1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-17 11:56:59 +01:00
psalm/docs/running_psalm/issues/InvalidTraversableImplementation.md
Bruce Weirdan 04bb2b1182
Prevent invalid Traversable implementation (#5171)
* Prevent invalid Traversable implementation

Fixes vimeo/psalm#5167

* Document new issue

* CS fix
2021-02-06 22:10:05 -05:00

269 B

InvalidTraversableImplementation

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

<?php

final class C implements Traversable {} // will cause fatal error