properly singletonize flattenRepType
replace castDBV hack with decidable equivalence
bump package version