Naive Either monad implementation