File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -233,6 +233,7 @@ public static function toIterator(iterable $iterable): \Iterator
233
233
$ iterable instanceof \Iterator => $ iterable ,
234
234
$ iterable instanceof \IteratorAggregate => self ::toIterator ($ iterable ->getIterator ()),
235
235
is_array ($ iterable ) => new \ArrayIterator ($ iterable ),
236
+ default => throw new Nette \ShouldNotHappenException ,
236
237
};
237
238
}
238
239
}
Original file line number Diff line number Diff line change @@ -104,3 +104,11 @@ class OutOfRangeException extends \OutOfRangeException
104
104
class UnexpectedValueException extends \UnexpectedValueException
105
105
{
106
106
}
107
+
108
+
109
+ /**
110
+ * Houston, we have a problem.
111
+ */
112
+ class ShouldNotHappenException extends \LogicException
113
+ {
114
+ }
You can’t perform that action at this time.
0 commit comments