Created: 2023-01-17 16:33

Instead of using Bool for binary types, or combinations of Bools in record fields for n-ary types, define specific types that convey a more precise meaning.

Eg. everybody gets confused about True meaning an item is kept or discarded in filter . This could be solved with an explicit type.

data Filter
  = Keep
  | Discard