def fix_integer_index(context, builder, idxty, idx, size):
 if idxty.signed:
  ind = context.cast(builder, idx, idxty, types.intp)
  ind = slicing.fix_index(builder, ind, size)
 else:
  ind = context.cast(builder, idx, idxty, types.uintp)
 return ind

def fix_integer_index ( context , builder , idxty , idx , size ) : if idxty . signed : ind = context . cast ( builder , idx , idxty , types . intp ) ind = slicing . fix_index ( builder , ind , size ) else : ind = context . cast ( builder , idx , idxty , types . uintp ) return ind
fix the integer index type and value for the given dimension size .