Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Enum is the preferred way to construct a sum type of several types (which does not implement the same trait).

The Rust crate either provides an enum Either (with variants Left and Right) which is a general purpose sum type with two cases.