Could you post a repro? With 1.9.4.19 I can compile these:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
 
let e : System.Collections.IEnumerable = ([1;2;3] :> System.Collections.IEnumerable)

[ for r in e -> r ] // enumerating an IEnumerable

type C() = 
    member x.GetEnumerator() = e.GetEnumerator()

[ for r in C() -> r ]  // enumerating a type that just has a GetEnumerator

type DEnum() = 
    member x.MoveNext() = true
    member x.Current = 1

type D() = 
    member x.GetEnumerator() = new DEnum()

[ for r in D() -> r ]  // enumerating a type that just has a GetEnumerator with the MoveNext/Current pattern

Seq.untyped_to_typed as a # type in its argument, which counts as a type variable.

Thanks!

don

By on 7/24/2008 7:53 AM ()
IntelliFactory Offices Copyright (c) 2011-2012 IntelliFactory. All rights reserved.
Home | Products | Consulting | Trainings | Blogs | Jobs | Contact Us | Terms of Use | Privacy Policy | Cookie Policy
Built with WebSharper