package qcheck-core

  1. Overview
  2. Docs

Module QCheck.ObservableSource

Observables are usable as arguments for random functions. The random function will observe its arguments in a way that is determined from the observable instance.

  • since 0.6
Sourcetype -'a t

An observable for 'a, packing a printer and other things.

Sourceval equal : 'a t -> 'a -> 'a -> bool
Sourceval hash : 'a t -> 'a -> int
Sourceval print : 'a t -> 'a Print.t
Sourceval unit : unit t
Sourceval bool : bool t
Sourceval int : int t
Sourceval int32 : int32 t
  • since 0.24
Sourceval int64 : int64 t
  • since 0.24
  • since 0.24
Sourceval float : float t
  • since 0.24
Sourceval string : string t
Sourceval bytes : bytes t
  • since 0.20
Sourceval char : char t
  • since 0.20
Sourceval make : ?eq:('a -> 'a -> bool) -> ?hash:('a -> int) -> 'a Print.t -> 'a t
Sourceval map : ('a -> 'b) -> 'b t -> 'a t
Sourceval option : 'a t -> 'a option t
Sourceval result : 'a t -> 'e t -> ('a, 'e) result t
  • since 0.24
Sourceval list : 'a t -> 'a list t
  • since 0.24
Sourceval array : 'a t -> 'a array t
Sourceval pair : 'a t -> 'b t -> ('a * 'b) t
Sourceval triple : 'a t -> 'b t -> 'c t -> ('a * 'b * 'c) t
Sourceval quad : 'a t -> 'b t -> 'c t -> 'd t -> ('a * 'b * 'c * 'd) t