ther is a languare that supports what Ikalman does, it is scala. Here an 
excerpt from the repl.
    
    
    
    scala> val a = Left(123)
    a: scala.util.Left[Int,Nothing] = Left(123)
    
    scala> val b = Right("hallo")
    b: scala.util.Right[Nothing,String] = Right(hallo)
    
    scala> var c : Either[Int,String] = null
    c: Either[Int,String] = null
    
    scala> c = b
    c: Either[Int,String] = Right(hallo)
    
    scala> c = a
    c: Either[Int,String] = Left(123)
    
    scala>
    

Scala has the `Nothing` type and type covariance. Type covariance can only work 
on reference types, and nim simply does not work that way.

Reply via email to