add type resolution memoizer