@@ -1513,6 +1513,12 @@ reifyReportPart (App (P (DCon _ _) n _) tm)
15131513 show tm ++
15141514 " when reflecting an error"
15151515 OK (tm', _) -> return $ TermPart tm'
1516+reifyReportPart (App (P (DCon _ _) n _) tm)
1517+ | n == reflErrName "SubReport" =
1518+ case unList tm of
1519+ Just xs -> do subParts <- mapM reifyReportPart xs
1520+ return (SubReport subParts)
1521+ Nothing -> ierror . InternalMsg $ "could not reify subreport " ++ show tm
15161522reifyReportPart x = ierror . InternalMsg $ "could not reify " ++ show x
15171523
15181524envTupleType :: Raw