title: Runtime creation of generic Func<T>
body: <p>I need to implement the method:   </p>
  
  <pre><code>object GetFactory(Type type);
  </code></pre>
  
  <p>This method needs to return a Func&lt;T&gt; where typeparam 'T' is the 'type'.</p>
  
  <p>So, my problem is that I don't know how to create a Func&lt;?&gt; at runtime using reflection. Activator.CreateInstance doesn't work because there are no constructors on delegates.</p>
  
  <p>Any Ideas?</p>