Use refactored makeTargetingCode in getInvocationCode.