C
cody
Why was this design decision to use this kind of "duck typing" in that case?
All you have to do is have a method GetEnumerator() which returns an
object providing Current and MoveNext(). IEnumerator and IEnumerable are
not necessary. Why is that? And what are these interface good for then?
Just dummy/marker interfaces like Cloneable in java?
All you have to do is have a method GetEnumerator() which returns an
object providing Current and MoveNext(). IEnumerator and IEnumerable are
not necessary. Why is that? And what are these interface good for then?
Just dummy/marker interfaces like Cloneable in java?