code: def generate_generic_arg_handling_body(num_args):
      gen = PythonCodeGenerator()
  
      if num_args == 0:
          gen("pass")
      else:
          gen_indices_and_args = []
          for i in range(num_args):
              gen_indices_and_args.append(i)
              gen_indices_and_args.append(f"arg{i}")
  
          gen(
              f"self._set_arg_multi("
              f"({', '.join(str(i) for i in gen_indices_and_args)},), "
              ")"
          )
  
      return gen
  
file_path: pyopencl/pyopencl/invoker.py
imports: import numpy
  from warnings import warn
  import pyopencl._cl
  from pytools.persistent_dict import WriteOncePersistentDict
  from pytools.py_codegen import Indentation, PythonCodeGenerator
  from pyopencl.tools import _NumpyTypesKeyBuilder, VectorArg
  import pyopencl
label_desc: Use image node_id 1 for calling a global function with example usage: generate_generic_arg_handling_body(num_args) and returns: gen