Cached

The following code makes cached (memoized) property f

class {
    @property string _f() { ... }
    mixin mixin Cached!"f";
}
mixin template Cached (
string name
string baseName = '_' ~ name
)

Meta