On 13-05-2012 19:27, Stewart Gordon wrote:
On 13/05/2012 18:04, Alex Rønne Petersen wrote:
<snip>
But how would you memoize the value in the instance of the object if
it's const?

By storing the memoized value outside of the object. Read the code of
std.functional.memoize - you'll see that it holds the values in a static
AA.

Stewart.

Which forces you to:

1) use an AA lookup
2) use the GC

Not an optimal solution IMHO.

--
- Alex

Reply via email to