title: Compare outer type of typing objects
body: <p>I'm developing a module for converting types that are defined using Python's <code>typing</code> library. I'd like to determine if the given type is a list as seen below:</p>
  <pre><code>def is_list(input_type):
     &quot;&quot;&quot;Return if the given input_type is List&quot;&quot;&quot;
  </code></pre>
  <pre><code>is_list(List[int]) -&gt; True
  is_list(List[str]) -&gt; True
  is_list(Dict[str, str]) -&gt; False
  </code></pre>
  <p>Is using <code>._name</code> the best approach here, or is there a better way to extract the outer type that doesn't require me to use a private attribute?</p>
  <pre><code>List[int]._name
  'List'
  </code></pre>