on master help sign in
Switch Type.Constraint to use Elm.Name
5a63520Evan Czaplicki
src/Type/Constraint.hs+5−4
@@ -9,9 +9,10 @@ module Type.Constraint
9 )
9 )
10 where
10 where
11
11
12+
12import qualified Data.Map.Strict as Map
13import qualified Data.Map.Strict as Map
13−import Data.Text (Text)
14
14
15+import qualified Elm.Name as N
15import qualified Reporting.Annotation as A
16import qualified Reporting.Annotation as A
16import qualified Reporting.Error.Type as Error
17import qualified Reporting.Error.Type as Error
17import qualified Reporting.Region as R
18import qualified Reporting.Region as R
@@ -35,7 +36,7 @@ data Constraint
35-- SCHEMES
36-- SCHEMES
36
37
37
38
38−type SchemeName = Text
39+type SchemeName = N.Name
39
40
40
41
41data Scheme =
42data Scheme =
@@ -43,7 +44,7 @@ data Scheme =
43 { _rigidQuantifiers :: [Variable]
44 { _rigidQuantifiers :: [Variable]
44 , _flexibleQuantifiers :: [Variable]
45 , _flexibleQuantifiers :: [Variable]
45 , _constraint :: Constraint
46 , _constraint :: Constraint
46− , _header :: Map.Map Text (A.Located Type)
47+ , _header :: Map.Map N.Name (A.Located Type)
47 }
48 }
48
49
49
50
@@ -51,7 +52,7 @@ data Scheme =
51-- SCHEME HELPERS
52-- SCHEME HELPERS
52
53
53
54
54−monoscheme :: Map.Map Text (A.Located Type) -> Scheme
55+monoscheme :: Map.Map N.Name (A.Located Type) -> Scheme
55monoscheme headers =
56monoscheme headers =
56 Scheme [] [] CTrue headers
57 Scheme [] [] CTrue headers
57
58