title: How should I call the generic function without knowing the type at compile time?
body: <p>Lets say, If I have a situation like the following.</p>
  
  <pre><code>
  Type somethingType = b.GetType();
      // b is an instance of Bar();
  
  Foo&lt;somethingType&gt;(); //Compilation error!!
      //I don't know what is the Type of "something" at compile time to call
      //like Foo&lt;Bar&gt;();
  
  
  //Where:
  public void Foo&lt;T&gt;()
  {
      //impl
  }
  </code></pre>
  
  <p>How should I call the generic function without knowing the type at compile time?</p>