stedolan / crowbar

Property fuzzing for OCaml
MIT License
180 stars 31 forks source link

Add concat_gen_list ('a) #42

Closed FooB4r closed 6 years ago

FooB4r commented 6 years ago

Added the function concat_gen_list

stedolan commented 6 years ago

I'm a bit uncomfortable with the fact that concat_gen_list fails on empty lists. I'm also unsure whether I'd want to use this for types other than string, since adding separators between elements seems useful only for strings. (Or do you already have a non-string use-case?)

How about going for a string-specific version now (which can return "" on empty lists, and need not be passed an append function), and we can revisit the API design when there's a use-case for the general one?

stedolan commented 6 years ago

Happy to merge this, but there's a conflict. (I think you changed the whitespace on the range line in crowbar.mli, which was also changed by #41 )