StandardML is a strong, statically typed language. Therefore, you cannot have a function that takes an int in the first case and a string in the second. Mistake:
this clause: string * string -> 'Z
previous clauses: int * string -> 'Z
in declaration:
firstStr =
(fn (0,<pat> : string) => n
| (<pat> : string,<pat> : string) => if <exp> > <exp> then n else b)
, , int, , tagged union "(aka" "), . :
datatype Wrapper = Int of int
| String of string
fun firstStr(Int 0, n:string) = n
| firstStr(String b, n:string) = if b>n then n else b
, Wrapper, . , n ;
fun firstStr(Int 0, n) = n
| firstStr(String b, n) = if b>n then n else b
, , : , , ?
, , b>n, ? , SML, (-) . , ?