datatype ('a,'b) sum = left of 'a | right of 'b; left(9); right("hello"); [left(9),right("hello")]; fun foo (left(x:int)) = 42 | foo (right(y:string)) = 0; foo(left(9)); foo(right("hello"));