Memoize can only work on a certain segment of argument types