category
Adds predicates for generating random values for selected types to the library "type" object.
Paulo Moura
1.13
2018/4/4
static
Table of defined types for which an arbitrary value can be generated. A new type can be registered by defining a clause for this predicate and adding a clause for the arbitrary/2 multifile predicate.
static, multifile
arbitrary(Type)
arbitrary(?callable) – zero_or_more
Generates an arbitrary term of the specified type. Fails if the given type is not supported. A new generator can be added by defining a clause for this predicate and registering it by adding a clause for the arbitrary/1 multifile predicate.
static, multifile
arbitrary(Type,Term)
arbitrary(@callable,-term) – zero_or_one
Shrinks a value to a smaller value. Fails if the given type is not supported or if shrinking the value is not possible. Support for a new type can be added by defining a clause for this predicate.
static, multifile
shrink(Type,Large,Small)
shrink(@callable,@term,-term) – zero_or_one
(see related entities)
(see related entities)