on master help sign in
Remove deprecatd classInfo method from REPL.hs
4168f05Paul Koerbitz
src/Idris/REPL.hs−25
@@ -1096,31 +1096,6 @@ process h fn (MakeDoc s) =
1096 Left err -> iPrintError err
1096 Left err -> iPrintError err
1097
1097
1098
1098
1099−classInfo :: ClassInfo -> Idris (Doc OutputAnnotation)
1100−classInfo ci = do ist <- getIState
1101− ctxt <- getContext
1102− return $
1103− text "Parameters:" <+>
1104− hsep (punctuate comma (map (prettyName False params') params)) <>
1105− line <> line <>
1106− text "Methods:" <> line <>
1107− indent 2 (vsep (map (dumpMethod ist) (class_methods ci))) <> line <> line <>
1108− text "Default superclass instances:" <>
1109− line <>
1110− indent 2 (vsep (map (dumpDefaultInstance ist) (class_default_superclasses ci))) <>
1111− line <>
1112− text "Instances:" <> line <>
1113− indent 2 (vsep (map (dumpInstance ist ctxt) (class_instances ci)))
1114− where dumpMethod :: IState -> (Name, (FnOpts, PTerm)) -> Doc OutputAnnotation
1115− dumpMethod ist (n, (_, t)) = prettyName False [] n <+> colon <+> pp ist t
1116− dumpDefaultInstance :: IState -> PDecl -> Doc OutputAnnotation
1117− dumpDefaultInstance ist (PInstance _ _ _ _ _ t _ _) = pp ist t
1118− dumpInstance :: IState -> Context -> Name -> Doc OutputAnnotation
1119− dumpInstance ist ctxt n = pp ist $ delabTy ist n
1120− params = class_params ci
1121− params' = zip params (repeat False)
1122− pp ist = pprintPTerm (opt_showimp (idris_options ist)) params' []
1123−
1124showTotal :: Totality -> IState -> String
1099showTotal :: Totality -> IState -> String
1125showTotal t@(Partial (Other ns)) i
1100showTotal t@(Partial (Other ns)) i
1126 = show t ++ "\n\t" ++ showSep "\n\t" (map (showTotalN i) ns)
1101 = show t ++ "\n\t" ++ showSep "\n\t" (map (showTotalN i) ns)