Note: I meant `require("lang/functional").memoize` instead of `cache`. Also it's in one of my pending patches to make it non leaky by default:
https://github.com/mozilla/addon-sdk/pull/1207/files#diff-89c45908f9f77832a5a132b7dfe14e7eR181

Maybe worth cherry-picknig and landing with an implementation of this JEP.