News for hackers. Stuff that matters.
Re:Where does the name "algebraic data type" come from? by kccqzy on Wednesday July 31, 2024 @06:28PM (#41124196)
You are not wrong but you are indeed a minority. If you read research papers you will definitely find papers that use union in the way you describe (when it comes to subtyping), and then use a different notation for record extension (basically the kind of discriminated union operator). It's essential to differentiate between them using different notations. For the former, for example the Animal class and the Cat class are unioned into the Animal superclass. For the latter, you have an Animal object and a Cat object that's separate.

There are no comments on this comment yet.