@@ -35,15 +35,15 @@ data Contract ty cryptolExpr =
35
35
, preAllocated :: [Allocated ty ]
36
36
, preGhostValues :: [GhostValue cryptolExpr ]
37
37
, prePointsTos :: [PointsTo ty cryptolExpr ]
38
- , prePointsToBitfields :: [PointsToBitfield cryptolExpr ]
39
- , argumentVals :: [CrucibleSetupVal cryptolExpr ]
38
+ , prePointsToBitfields :: [PointsToBitfield ty cryptolExpr ]
39
+ , argumentVals :: [CrucibleSetupVal ty cryptolExpr ]
40
40
, postVars :: [ContractVar ty ]
41
41
, postConds :: [cryptolExpr ]
42
42
, postAllocated :: [Allocated ty ]
43
43
, postGhostValues :: [GhostValue cryptolExpr ]
44
44
, postPointsTos :: [PointsTo ty cryptolExpr ]
45
- , postPointsToBitfields :: [PointsToBitfield cryptolExpr ]
46
- , returnVal :: Maybe (CrucibleSetupVal cryptolExpr )
45
+ , postPointsToBitfields :: [PointsToBitfield ty cryptolExpr ]
46
+ , returnVal :: Maybe (CrucibleSetupVal ty cryptolExpr )
47
47
}
48
48
deriving stock (Functor , Foldable , Traversable )
49
49
@@ -64,17 +64,17 @@ data Allocated ty =
64
64
65
65
data PointsTo ty cryptolExpr =
66
66
PointsTo
67
- { pointer :: CrucibleSetupVal cryptolExpr
68
- , pointsTo :: CrucibleSetupVal cryptolExpr
67
+ { pointer :: CrucibleSetupVal ty cryptolExpr
68
+ , pointsTo :: CrucibleSetupVal ty cryptolExpr
69
69
, checkPointsToType :: Maybe (CheckPointsToType ty )
70
70
, condition :: Maybe cryptolExpr
71
71
} deriving stock (Functor , Foldable , Traversable )
72
72
73
- data PointsToBitfield cryptolExpr =
73
+ data PointsToBitfield ty cryptolExpr =
74
74
PointsToBitfield
75
- { bfPointer :: CrucibleSetupVal cryptolExpr
75
+ { bfPointer :: CrucibleSetupVal ty cryptolExpr
76
76
, bfFieldName :: Text
77
- , bfPointsTo :: CrucibleSetupVal cryptolExpr
77
+ , bfPointsTo :: CrucibleSetupVal ty cryptolExpr
78
78
} deriving stock (Functor , Foldable , Traversable )
79
79
80
80
data CheckAgainstTag
@@ -96,7 +96,7 @@ instance (FromJSON ty, FromJSON cryptolExpr) => FromJSON (PointsTo ty cryptolExp
96
96
<*> o .:? " check points to type"
97
97
<*> o .:? " condition"
98
98
99
- instance FromJSON cryptolExpr => FromJSON (PointsToBitfield cryptolExpr ) where
99
+ instance ( FromJSON ty , FromJSON cryptolExpr ) => FromJSON (PointsToBitfield ty cryptolExpr ) where
100
100
parseJSON =
101
101
withObject " Points-to-bitfield relationship" $ \ o ->
102
102
PointsToBitfield <$> o .: " pointer"
0 commit comments