-->
type nullableString(object o)
return string(o) or o=NULL
end type
nullableString s
s = "hello"
s = NULL
--s = 1 -- error
--s = {1,2,3} -- error
type nullableSequence(object o)
return sequence(o) or o=NULL
end type
nullableSequence q
q = {1,2,3}
q = "string" -- fine (strings are a subset of sequences)
q = NULL
--q = 1 -- error