@@ -380,7 +380,7 @@ pprintErr' i (ReflectionFailed msg err) =
380 text "When attempting to perform error reflection, the following internal error occurred:" <>
380 text "When attempting to perform error reflection, the following internal error occurred:" <>
381 indented (pprintErr' i err) <>
381 indented (pprintErr' i err) <>
382 text ("This is probably a bug. Please consider reporting it at " ++ bugaddr)
382 text ("This is probably a bug. Please consider reporting it at " ++ bugaddr)
383−pprintErr' i (ElabDebug msg tm holes) =
383+pprintErr' i (ElabScriptDebug msg tm holes) =
384 text "Elaboration halted." <>
384 text "Elaboration halted." <>
385 maybe empty (indented . text) msg <> line <>
385 maybe empty (indented . text) msg <> line <>
386 text "Term: " <> indented (pprintTT [] tm) <> line <>
386 text "Term: " <> indented (pprintTT [] tm) <> line <>
@@ -401,6 +401,9 @@ pprintErr' i (ElabDebug msg tm holes) =
401 pprintTT ns (binderTy b) <>
401 pprintTT ns (binderTy b) <>
403 ppAssumptions (n:ns) rest
403 ppAssumptions (n:ns) rest
404+pprintErr' i (ElabScriptStuck tm) =
405+ text "Can't run" <+> pprintTT [] tm <+> text "as an elaborator script." <$>
406+ text "Is it a stuck term?"
405-- | Make sure the machine invented names are shown helpfully to the user, so
408-- | Make sure the machine invented names are shown helpfully to the user, so
406-- that any names which differ internally also differ visibly
409-- that any names which differ internally also differ visibly