generics - Haxe Interface that extends Iterable -


i have interface extends iterable (as other interfaces).

interface myinterface extends iterable {   public function iterator ():iterator<dynamic>; } 

this gives me

myinterface.hx:1: lines 1-3 : invalid number of type parameters iterable

what correct way proceed?

iterable defined typedef, not interface, can't work.

simply adding function named iterator() class trick, no need implement or extend anything. there's more information iterators on haxe manual.


Comments

Popular posts from this blog

javascript - Google App Script ContentService downloadAsFile not working -

javascript - Function overwritting -

c# - Exception when attempting to modify Dictionary -