Skip to content

Commit 7e6acbf

Browse files
Improve docs
1 parent 6228183 commit 7e6acbf

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Constrained/Base.hs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,10 @@ class
488488
-- | Shrink an `a` with the aide of a `TypeSpec`
489489
shrinkWithTypeSpec :: TypeSpec a -> a -> [a]
490490

491-
-- | Try to make an `a` conform to `TypeSpec` with minimal changes
491+
-- | Try to make an `a` conform to `TypeSpec` with minimal changes. When
492+
-- `fixupWithSpec ts a` returns `Just a'`, it should be the case that
493+
-- `conformsTo a' ts`. There are no constraints in the `Nothing` case. A
494+
-- non-trivial implementation of this function is important for shrinking.
492495
fixupWithTypeSpec :: TypeSpec a -> a -> Maybe a
493496

494497
-- | Convert a spec to predicates:

0 commit comments

Comments
 (0)