top | item 28265441

(no title)

chajath | 4 years ago

What pain point of Python as an education language is Pyret trying to address? Union type might be vaguely useful, although some of these use cases can be modelled as inheritance or typed enums.

discuss

order

sharno|4 years ago

IMHO, Union types are the one the most important features that should have been in programming languages since C. And I believe it would have made our software much more bug free than it is generally now. Enums in all languages should be Rust like enums with exhaustive checking and allow recursive definitions.