@@ -139,6 +139,7 @@ data SimpleErrorMessage
139 | IntOutOfRange Integer String Integer Integer
139 | IntOutOfRange Integer String Integer Integer
140 | RedundantEmptyHidingImport ModuleName
140 | RedundantEmptyHidingImport ModuleName
141 | ImplicitImport ModuleName [DeclarationRef]
141 | ImplicitImport ModuleName [DeclarationRef]
142+ | ImplicitDctorImport ProperName [ProperName]
142 | CaseBinderLengthDiffers Int [Binder]
143 | CaseBinderLengthDiffers Int [Binder]
143 deriving (Show)
144 deriving (Show)
@@ -310,6 +311,7 @@ errorCode em = case unwrapErrorMessage em of
310 IntOutOfRange{} -> "IntOutOfRange"
311 IntOutOfRange{} -> "IntOutOfRange"
311 RedundantEmptyHidingImport{} -> "RedundantEmptyHidingImport"
312 RedundantEmptyHidingImport{} -> "RedundantEmptyHidingImport"
312 ImplicitImport{} -> "ImplicitImport"
313 ImplicitImport{} -> "ImplicitImport"
314+ ImplicitDctorImport{} -> "ImplicitDctorImport"
313 CaseBinderLengthDiffers{} -> "CaseBinderLengthDiffers"
315 CaseBinderLengthDiffers{} -> "CaseBinderLengthDiffers"
@@ -859,6 +861,11 @@ prettyPrintSingleError full level e = flip evalState defaultUnknownMap $ do
859 , indent $ line $ "import " ++ runModuleName mn ++ " (" ++ intercalate ", " (map prettyPrintRef refs) ++ ")"
861 , indent $ line $ "import " ++ runModuleName mn ++ " (" ++ intercalate ", " (map prettyPrintRef refs) ++ ")"
864+ renderSimpleErrorMessage (ImplicitDctorImport ty ctors) =
865+ paras [ line $ "Import of type " ++ runProperName ty ++ " has unspecified data constructors, consider using the explicit form: "
866+ , indent $ line $ runProperName ty ++ " (" ++ intercalate ", " (map runProperName ctors) ++ ")"
862 renderSimpleErrorMessage (CaseBinderLengthDiffers l bs) =
869 renderSimpleErrorMessage (CaseBinderLengthDiffers l bs) =
863 paras $ [ line $ "Binder list length differs in case alternative:"
870 paras $ [ line $ "Binder list length differs in case alternative:"
864 , indent $ line $ intercalate ", " $ fmap prettyPrintBinderAtom bs
871 , indent $ line $ intercalate ", " $ fmap prettyPrintBinderAtom bs