-- |composeSubsts a b sequentially composes a and b
-- |such that a is applied after b.
composeVarSubsts :: VarsIn a => VarSubsts a -> VarSubsts a -> VarSubsts a
composeVarSubsts a b = (IM.map (\bv -> applyVarSubsts a bv) b) `union` a
composeVarSubsts :: VarsIn a => VarSubsts a -> VarSubsts a -> VarSubsts a
composeVarSubsts a b = (IM.map (\bv -> applyVarSubsts a bv) b) `union` a
composeVarSubsts a b = (IM.map (\bv -> applyVarSubsts a bv) b) `union` a