title: Typescript extending Enum
body: <p>The case is you have a list of constants or Enum how you can do it ?</p>
  
  <p>Here is the pseudo example code:</p>
  
  <pre><code>enum MyList
  {
      A,
      B
  }
  
  enum MyList2
  {
      C
  }
  
  
  function test&lt;T&gt;(input:MyList | T):void
  {
  
  }
  
  test&lt;MyList2&gt;(123) // compiler does not identify that 123 is not a supported
  </code></pre>