Module Shape_reduce.Make

The Make functor is used to generate a reduction function for shapes.

It is parametrized by:

Usage warning: To ensure good performances, every reduction made with the same instance of that functor share the same ident-based memoization tables. Such an instance should only be used to perform reduction inside a unique compilation unit to prevent conflicting entries in these memoization tables.

Parameters

module _ : sig ... end

Signature

val reduce : Env.t -> Shape.t -> Shape.t
val reduce_for_uid : Env.t -> Shape.t -> result

Perform weak reduction and return the head's uid if any. If reduction was incomplete the partially reduced shape is returned.