sum types are are not all that different from subtyping+inheritance, it's simply the other side of the expression problem.
That's a huge difference in terms of code architecture - it enables things like exhaustive pattern matching, and allows the programmer to enforce stronger invariants in the code.
This is simply a distinction between closed and open sum types.
[1] https://caml.inria.fr/pub/docs/manual-ocaml/extn.html#s%3Aex...
[2] http://caml.inria.fr/pub/docs/manual-ocaml-400/manual006.htm...
> The "expression problem" is a phrase used to describe a dual problem that neither ObjectOrientedProgramming nor FunctionalProgramming fully addresses.
"dual problem", meaning you choose ObjectOrientedProgramming or FunctionalProgramming, which neither fully address.
neither "side" is able to resolve the ExpressionProblem