So I am currently writing code that generates objects at run time. Much like in This Q&A.
However I'm having trouble finding any information regarding dynamically creating a type with that same type embedded in it. something like:
public class Foo
{
private Foo _Parent
public Foo()
{}
public Foo Parent
{
get { return _Parent; }
set { _Parent = value; }
}
}
Is there any way to do this in c# using reflection or emit?
Thanks in advance.