We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7cb5442 commit 82f6536Copy full SHA for 82f6536
src/Constrained/Spec/List.hs
@@ -274,6 +274,7 @@ randomInterleaving xs ys = go xs ys (length ys)
274
go [] ys _ = pure ys
275
go xs [] _ = pure xs
276
go xs ys l = do
277
+ -- TODO: think about distribution here
278
i <- choose (0, l)
279
go' i xs ys (l - i)
280
@@ -282,11 +283,6 @@ randomInterleaving xs ys = go xs ys (length ys)
282
283
go' 0 (x:xs) ys l = (x:) <$> go xs ys l
284
go' i xs (y:ys) l = (y:) <$> go' (i-1) xs ys l
285
-genSplit :: [a] -> Gen ([a], [a])
286
-genSplit as = do
287
- s <- choose (0, length as)
288
- return $ splitAt s as
289
-
290
instance HasSpec a => HasGenHint [a] where
291
type Hint [a] = Integer
292
giveHint szHint = typeSpec $ ListSpec (Just szHint) [] mempty mempty NoFold
0 commit comments