title: How do I create an instance of the Array type with a given ElementType?
body: <p>How do I create a type object that represents the type of an array with a given element type?</p>
  
  <pre><code>Type t = MakeArrayType(elementType);  // How?
  </code></pre>
  
  <p>Such that</p>
  
  <pre><code>Assert(t.GetElementType() == elementType);
  </code></pre>
  
  <p>I can create a dummy <em>instance</em> of my requested array and then get the type from there. But I wonder if there is a way to get the type without creating the instance first?</p>
  
  <pre><code>object myArrayInstance = Array.CreateInstance(elementType, 0);
  Type t = myArrayInstance.GetType();   // This is the desired type.
  </code></pre>