inline types memoization