It's very rare for a single variable type to have integer and non-integer instances.
Define a class which a Variable must be an instance of.
data Type = Continuous | Binary | Integer
data Bound = Fin Int | Infinite
newtype Bounded = Bounded (Bound, Bound)
class isVar a where
hasType :: a -> Type
hasBound :: a -> Bounded