public static nums() => yields<int>{ yield(0); yield(1); yield(2); }public static some nums => yields<int>{ yield(0); yield(1); yield(2); }public static good many nums => yields<int>{ yield(0); yield(1); yield(2); }//// bug #39//public static (int min) to (int max) => yields{ int x = min; do{ yield(x); x = x+1;}while(xpublic static delegate yieldDel() => yields<int>;public static main()=>void{foreach(int x in nums()){ print x; } foreach(int x in some nums){ print x; } foreach(int x in good many nums){ print x; } yieldDel = nums; foreach(int x in yieldDel()){ print x; }}
012012012012
Infix methods as generators don't quite work yet, but at least I identified that. They'll work soon enough.