Skip to content

Refer people to QC's GenT type as a default implementation for MonadGen #25

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 13, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@

A type class for random generator implementations.

Note that this library only provides the `MonadGen` type class; it does not provide any implementations of it. The intention is that libraries may depend on `purescript-gen` in order to provide functions for random generation of any data types they define while also keeping their dependency footprints minimal, and not tying users to any specific random generation library (since any library implementing random generation of values should be able to implement the `MonadGen` interface).

## Installation

```
Expand Down
3 changes: 3 additions & 0 deletions src/Control/Monad/Gen/Class.purs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ import Prelude
-- |
-- | Instances should provide implementations for the generation functions
-- | that return choices with uniform probability.
-- |
-- | See also `Gen` in `purescript-quickcheck`, which implements this
-- | type class.
class Monad m <= MonadGen m where

-- | Chooses an integer in the specified (inclusive) range.
Expand Down