Skip to content

Commit

Permalink
Merge pull request #428 from Trundle/fix_choose_scaladoc
Browse files Browse the repository at this point in the history
Fix Scaladoc: choose throws an exception if the range is invalid
  • Loading branch information
rickynils authored Sep 25, 2018
2 parents 782853c + 6317b01 commit e7714eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/scala/org/scalacheck/Gen.scala
Original file line number Diff line number Diff line change
Expand Up @@ -442,8 +442,8 @@ object Gen extends GenArities{
}

/** A generator that generates a random value in the given (inclusive)
* range. If the range is invalid, the generator will not generate
* any value. */
* range. If the range is invalid, an IllegalBoundsError exception will be
* thrown. */
def choose[T](min: T, max: T)(implicit c: Choose[T]): Gen[T] =
c.choose(min, max)

Expand Down

0 comments on commit e7714eb

Please sign in to comment.