@@ -51,7 +51,8 @@ import Data.Typeable hiding (typeOf)
51
51
import Data.Void
52
52
import Language.CQL.Collage (Collage (.. ), assembleGens , attsFrom , fksFrom , typeOf )
53
53
import Language.CQL.Common (elem' , intercalate , fromListAccum , mapl , section , toMapSafely , Deps (.. ), Err , Kind (INSTANCE ), MultiTyMap , TyMap , type (+ ))
54
- import Language.CQL.Instance.Presentation (Presentation (.. ), presToCol , typecheckPresentation , eqs0 )
54
+ import Language.CQL.Instance.Presentation (Presentation (.. ), presToCol , eqs0 )
55
+ import qualified Language.CQL.Instance.Presentation as IP (typecheck )
55
56
import Language.CQL.Mapping as Mapping
56
57
import Language.CQL.Options
57
58
import Language.CQL.Prover
@@ -133,12 +134,12 @@ down1 (Gen g) = Gen g
133
134
down1 (Fk f a) = Fk f $ down1 a
134
135
down1 _ = error " Anomaly: please report. Function name: down1."
135
136
136
- -- | Checks that an instance satisfies its schema .
137
- checkSatisfaction
137
+ -- | Checks that an 'Instance' satisfies its 'Schema' .
138
+ satisfiesSchema
138
139
:: (MultiTyMap '[Show ] '[var , ty , sym , en , fk , att , gen , sk , x , y ], Eq x )
139
140
=> Instance var ty sym en fk att gen sk x y
140
141
-> Err ()
141
- checkSatisfaction (Instance sch pres' dp' alg) = do
142
+ satisfiesSchema (Instance sch pres' dp' alg) = do
142
143
mapM_ (\ (EQ (l, r)) -> if hasTypeType l then report (show l) (show r) (instEqT l r) else report (show l) (show r) (instEqE l r)) $ Set. toList $ eqs0 pres'
143
144
mapM_ (\ (en'', EQ (l, r)) -> report (show l) (show r) (schEqT l r en'')) $ Set. toList $ obs_eqs sch
144
145
mapM_ (\ (en'', EQ (l, r)) -> report (show l) (show r) (schEqE l r en'')) $ Set. toList $ path_eqs sch
0 commit comments