From 630d78ae2ab6f829f4c531e62d46d50e0aa230e0 Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Sat, 22 Jul 2017 15:41:56 -0400 Subject: [PATCH] :fire: the Show1 instance for Error. --- src/Data/Syntax/Assignment.hs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/Data/Syntax/Assignment.hs b/src/Data/Syntax/Assignment.hs index 382ed79cb..aacf68c0f 100644 --- a/src/Data/Syntax/Assignment.hs +++ b/src/Data/Syntax/Assignment.hs @@ -336,10 +336,6 @@ instance Show grammar => Show1 (AssignmentF ast grammar) where Throw e -> showsUnaryWith showsPrec "Throw" d e Catch during handler -> showsBinaryWith sp (const (const (showChar '_'))) "Catch" d during handler -instance Show1 Error where - liftShowsPrec sp sl d UnexpectedSymbol{..} = showParen (d > 10) $ showString "UnexpectedSymbol" . showChar ' ' . showsPrec 11 errorPos . showChar ' ' . liftShowsPrec sp sl 11 errorExpected . showChar ' ' . sp 11 errorActual - liftShowsPrec sp sl d UnexpectedEndOfInput{..} = showsBinaryWith showsPrec (liftShowsPrec sp sl) "UnexpectedEndOfInput" d errorPos errorExpected - instance MonadError (Error grammar) (Assignment ast grammar) where throwError :: HasCallStack => Error grammar -> Assignment ast grammar a throwError error = withFrozenCallStack $ Throw error `Then` return