1 unstable release

Uses old Rust 2015

0.1.0 Oct 14, 2016

#748 in #memory

Apache-2.0

590KB
134 lines

Memoization

Documentation

Is a relatively simple crate that allows for structure fields to be memoized in a fairly light weight way. It handles most the messy memory overloading so when treated a structure field it can be DefMut, Def, and Borrowed as it's native output data type.

TODO: Port project to core as dependence on std isn't necessary.


lib.rs:

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.

No runtime deps