minor refactoring in typing_check_service.profile_log