namespace MyNamespace
import System
import System.Collections.Generic
import Boo.Lang.Compiler
[Extension]
def IndexWhere[of T]([Required] coll as IEnumerable[of T], [Required] filter as Func[of T, bool]) as IEnumerable[of int]:
return IndexWhereImpl(coll, filter)
private def IndexWhereImpl[of T](coll as IEnumerable[of T], filter as Func[of T, bool]) as IEnumerable[of int]:
index = 0
for value in coll:
if filter(value):
yield index
++index
Expected: This should work
Observed: Internal compiler error: Failed to create 'MyNamespace.MyNamespaceModule.$IndexWhereImpl$248.$' type.. (BCE0055)
Expected: This should work Observed: Internal compiler error: Failed to create 'MyNamespace.MyNamespaceModule.$IndexWhereImpl$248.$' type.. (BCE0055)