on ffe32c7 help sign in
elk/src/Reporting/Error/CheckMatch.hs
24 lines 448 B history raw
1module Reporting.Error.CheckMatch where
3import qualified Data.Aeson as Json
5import qualified AST.Variable as Var
6import qualified Reporting.Region as R
8data Error = ConstructorTypeNotFound Var.Canonical
10-- TO STRING
12toString :: R.Region -> Error -> String
13toString region err =
14 case err of
15 _ -> error "CheckMatch.toString" region
18-- TO JSON
20toJson :: Error -> Json.Value
21toJson err =
22 case err of
23 _ -> error "CheckMatch.toJson"