Refactoring valueFlowSubFunction