@@ -26,9 +26,7 @@ main = defaultMain [ testCase "lookupLT" test_lookupLT
26
26
, testProperty " prop_SingletonValid" prop_SingletonValid
27
27
, testProperty " prop_InsertIntoEmptyValid" prop_InsertIntoEmptyValid
28
28
, testProperty " prop_instanceEqIntSet" prop_instanceEqIntSet
29
- , testProperty " prop_instanceEqIntSet'" prop_instanceEqIntSet'
30
29
, testProperty " prop_instanceOrdIntSet" prop_instanceOrdIntSet
31
- , testProperty " prop_instanceOrdIntSet'" prop_instanceOrdIntSet'
32
30
, testProperty " prop_Single" prop_Single
33
31
, testProperty " prop_Member" prop_Member
34
32
, testProperty " prop_NotMember" prop_NotMember
@@ -113,18 +111,9 @@ test_split = do
113
111
--------------------------------------------------------------------}
114
112
instance Arbitrary IntSet where
115
113
arbitrary = do { xs <- arbitrary
116
- ; return (fromList xs )
114
+ ; return (fromList ( fmap getLarge xs) )
117
115
}
118
116
119
- newtype LargeInt = LargeInt { unLargeInt :: Int }
120
-
121
- instance Arbitrary LargeInt where
122
- arbitrary = ( \ (x,y) -> LargeInt $ if x == 0 then y else signum x * (2 ^ abs x) * y) <$> arbitrary
123
-
124
- newtype LargeIntSet = LargeIntSet IntSet deriving Show
125
- instance Arbitrary LargeIntSet where
126
- arbitrary = (LargeIntSet . fromList . fmap unLargeInt) <$> arbitrary
127
-
128
117
{- -------------------------------------------------------------------
129
118
Valid IntMaps
130
119
--------------------------------------------------------------------}
@@ -164,15 +153,9 @@ prop_InsertIntoEmptyValid x =
164
153
prop_instanceEqIntSet :: IntSet -> IntSet -> Bool
165
154
prop_instanceEqIntSet x y = (x == y) == (toAscList x == toAscList y)
166
155
167
- prop_instanceEqIntSet' :: LargeIntSet -> LargeIntSet -> Bool
168
- prop_instanceEqIntSet' (LargeIntSet x) (LargeIntSet y) = (x == y) == (toAscList x == toAscList y)
169
-
170
156
prop_instanceOrdIntSet :: IntSet -> IntSet -> Bool
171
157
prop_instanceOrdIntSet x y = (compare x y) == (compare (toAscList x) (toAscList y))
172
158
173
- prop_instanceOrdIntSet' :: LargeIntSet -> LargeIntSet -> Bool
174
- prop_instanceOrdIntSet' (LargeIntSet x) (LargeIntSet y) = (compare x y) == (compare (toAscList x) (toAscList y))
175
-
176
159
{- -------------------------------------------------------------------
177
160
Single, Member, Insert, Delete, Member, FromList
178
161
--------------------------------------------------------------------}
0 commit comments