module type Pool = sig
.. end
module type S = Pool_intf.S
module Obj_array: S
with type 'a Pointer.t = private int
Obj_array
is an efficient implementation of pools that uses a single chunk of
memory, and is what an application should ultimately use.
module None: S
None
is an inefficient implementation of pools that uses OCaml's memory allocator
to allocate each object.
module Debug: functor (
Pool
:
S
) ->
sig
.. end
Debug
builds a pool in which every function can run invariant
on its pool
argument(s) and/or print a debug message to stderr, as determined by
!check_invariant
and !show_messages
, which are initially both true
.
module Error_check:
Error_check
builds a pool that has additional error checking for pointers, in
particular to catch using a freed pointer or multiply freeing a pointer.