defrecord deftype reify for typed class, extend with protocol. pattern match knows all patterns. algebra subtype knows all fns on the subtype