code: def _index_code(idx):
      if idx.is_slice:
          values = idx.start, idx.stop, idx.step
          if idx.step.is_none:
              func = "contiguous_slice"
              values = values[:2]
          else:
              func = "slice"
          return "pythonic::types::%s(%s)" % (
              func,
              ",".join((v.pythran_result() for v in values)),
          )
      elif idx.type.is_int:
          return to_pythran(idx)
      elif idx.type.is_pythran_expr:
          return idx.pythran_result()
      raise ValueError("unsupported indexing type %s" % idx.type)
  
imports: from __future__ import absolute_import
  from .PyrexTypes import CType, CTypedefType, CStructOrUnionType
  import cython
label_desc: Use image node_id 9 for calling a global function with example usage: _index_code(idx) and returns: unknown, to_pythran, idx