{- Combinator used to generate the application of the mutual
   induction/recursion principle. -}

mutPfStart :: Sort
           -> [Name]    -- Names of types.
           -> String
mutPfStart s ns = f (case s of { Prop -> mutIndName ; Set -> mutRecName })
    where
      f g = printf "%s %s;\n" applyMutInd (g ns)


{- ----------------------------------------------------------------------- -}
{- * Looping patterns -}

{- Combinator used to loop over a set of @nt1s@. -}
mutPfStart :: Sort
           -> [Name]    -- Names of types.
           -> String
mutPfStart s ns = f (case s of { Prop -> mutIndName ; Set -> mutRecName })
    where
      f g = printf "%s %s;\n" applyMutInd (g ns)


{- ----------------------------------------------------------------------- -}
{- * Looping patterns -}

{- Combinator used to loop over a set of @nt1s@. -}
mutPfStart s ns = f (case s of { Prop -> mutIndName ; Set -> mutRecName })
    where
      f g = printf "%s %s;\n" applyMutInd (g ns)


{- ----------------------------------------------------------------------- -}
{- * Looping patterns -}

{- Combinator used to loop over a set of @nt1s@. -}