Decompile Iterator blocks

Decompile Iterator blocks

Postby matzeook » Fri Jan 13, 2012 5:18 pm

I just downloaded the Reflector trial version and tried to decompile an test assembly including the IteratorSample Method from your web site.

Code: Select all
public static IEnumerable<int>IteratorSample()
            for (int i = 0; i < 10; i++)
                yield return i;

Decompiling this code results in

private sealed class <IteratorSample>d__0 : IEnumerable<int>, IEnumerable, IEnumerator<int>, IEnumerator, IDisposable
and all those
private int <>1__state
private int <>2__current;
private int <>l__initialThreadId;
public int <i>5__1;

Is this a bug?
The LamdaExample and LinqSample were decompiled as they are in source code.
Posts: 1
Joined: Fri Jan 13, 2012 1:37 pm

Return to .NET Reflector 7.0 Feedback

Who is online

Users browsing this forum: No registered users and 0 guests