Crate memoization [] [src]

Memoization offers a simple generic enum that allows for variables and structure fields to become memoized. The generic signature is pretty ugly but a user should be able to contain that within a structure. This is a fairly powerful pattern.

The deref, derefmut, and borrow fields are overloaded. So as a structure field the contained data can be written to, and borrowed much like a normal field.

I believe this should be able to be ported to core, as none of its codee necessarily needs standard. This maybe a future project.



The enumerator that holds data. In its pre-processed state it holds a pointer to the lambda that assigns its future constant value.