Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
public interface IHaveDeferredEnumerable
{
IEnumerable<IHaveDeferredEnumerable> Get();
}
public class HasDeferredEnumerable : IHaveDeferredEnumerable
{
public IEnumerable<IHaveDeferredEnumerable> Get()
{
yield return null;
}
}
public class HasDeferredEnumerable : IHaveDeferredEnumerable
{
public HasDeferredEnumerable()
{
base.\u002Ector();
}
[IteratorStateMachine(typeof (HasDeferredEnumerable.\u003CGet\u003Ed__0))]
public IEnumerable<IHaveDeferredEnumerable> Get()
{
return (IEnumerable<IHaveDeferredEnumerable>) new HasDeferredEnumerable.\u003CGet\u003Ed__0(-2);
}
[CompilerGenerated]
private sealed class \u003CGet\u003Ed__0 : IEnumerable<IHaveDeferredEnumerable>, IEnumerable, IEnumerator<IHaveDeferredEnumerable>, IDisposable, IEnumerator
{
[DebuggerHidden]
public \u003CGet\u003Ed__0(int \u003C\u003E1__state)
{
base.\u002Ector();
this.\u003C\u003E1__state = param0;
this.\u003C\u003El__initialThreadId = Environment.get_CurrentManagedThreadId();
}
//removed implementation for simplicity
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment