Place the pointer at indexA in indexB and vice versa.
975246
final void swapPointers(int indexA, int indexB) {
    assert indexA >= 0 && indexA < valuesHeld;
    assert indexB >= 0 && indexB < valuesHeld;

    ByteBuffer a = copyPointer(indexA);
    ByteBuffer b = readPointer(indexB);
    writePointer(indexA, b);
    writePointer(indexB, a);
  }
413755
def insertBPoint(self, index, type=None, anchor=None, bcpIn=None, bcpOut=None, bPoint=None):
        
        if bPoint is not None:
            if type is None:
                type = bPoint.type
            if anchor is None:
                anchor = bPoint.anchor
            if bcpIn is None:
                bcpIn = bPoint.bcpIn
            if bcpOut is None:
                bcpOut = bPoint.bcpOut
        index = normalizers.normalizeIndex(index)
        type = normalizers.normalizeBPointType(type)
        anchor = normalizers.normalizeCoordinateTuple(anchor)
        if bcpIn is None:
            bcpIn = (0, 0)
        bcpIn = normalizers.normalizeCoordinateTuple(bcpIn)
        if bcpOut is None:
            bcpOut = (0, 0)
        bcpOut = normalizers.normalizeCoordinateTuple(bcpOut)
        self._insertBPoint(index=index, type=type, anchor=anchor,
                           bcpIn=bcpIn, bcpOut=bcpOut)
1184569
private void indexArrayStore(int e, int i)
    {
        if (valueIndexStore.length < e)
        {
            int oldLength = valueIndexStore.length;
            valueIndexStore = Arrays.copyOf(valueIndexStore, e + 2);
            Arrays.fill(valueIndexStore, oldLength, valueIndexStore.length, -1);
        }
        valueIndexStore[e] = i;
    }
363436
def index(a, x, atol=None):
    """"""
    i = bs.bisect_left(a, x)
    if i != len(a):
        if atol is None:
            if a[i] == x: return i
        else:
            if abs(a[i] - x) < atol: return i
    raise ValueError
828614
void reindex(Session session, Index index) {

        setAccessor(index, null);

        RowIterator it = table.rowIterator(session);

        while (it.hasNext()) {
            Row row = it.getNextRow();

            // may need to clear the node before insert
            index.insert(session, this, row);
        }
    }
870364
def _insertBPoint(self, index, type, anchor, bcpIn, bcpOut, **kwargs):
        
        # insert a simple line segment at the given anchor
        # look it up as a bPoint and change the bcpIn and bcpOut there
        # this avoids code duplication
        self._insertSegment(index=index, type="line",
                            points=[anchor], smooth=False)
        bPoints = self.bPoints
        index += 1
        if index >= len(bPoints):
            # its an append instead of an insert
            # so take the last bPoint
            index = -1
        bPoint = bPoints[index]
        bPoint.bcpIn = bcpIn
        bPoint.bcpOut = bcpOut
        bPoint.type = type
40299
protected static void multTransBBlockMinus( final double[] dataA, final double []dataC,
                                                final int indexA, final int indexB, final int indexC,
                                                final int widthA, final int heightA, final int widthC ) {
//        for( int i = 0; i < heightA; i++ ) {
//            for( int j = 0; j < widthC; j++ ) {
//                double sum = 0;
//                for( int k = 0; k < widthA; k++ ) {
//                    sum += dataA[i*widthA + k + indexA] * dataA[j*widthA + k + indexB];
//                }
//                dataC[ i*widthC + j + indexC ] -= sum;
//            }
//        }
        
        int rowA = indexA;
        int c = indexC;
        for( int i = 0; i < heightA; i++ , rowA += widthA ) {
            final int endA = rowA + widthA;
            int rowB = indexB;
            final int endLoopJ = c + widthC;

            // for( int j = 0; j < widthC; j++  ) {
            while( c != endLoopJ ) {
                int a = rowA;
                int b = rowB;

                double sum = 0;
                while( a != endA ) {
                    sum += dataA[a++] * dataA[b++];
                }
                dataC[ c++ ] -= sum;
                rowB += widthA;
            }
        }
    }
771220
private void ssInsertionSort(int PA, int first, int last, int depth) {
        // PA, first, last are pointers in SA
        int i, j;// pointers in SA
        int t, r;

        for (i = last - 2; first <= i; --i) {
            for (t = SA[i], j = i + 1; 0 < (r = ssCompare(PA + t, PA + SA[j], depth)); ) {
                do {
                    SA[j - 1] = SA[j];
                }
                while ((++j < last) && (SA[j] < 0));
                if (last <= j) {
                    break;
                }
            }
            if (r == 0) {
                SA[j] = ~SA[j];
            }
            SA[j - 1] = t;
        }

    }
1335925
function (mMap, sPath, oItem) {
			if (oItem) {
				if (!mMap[sPath]) {
					mMap[sPath] = [oItem];
				} else if (mMap[sPath].indexOf(oItem) < 0) {
					mMap[sPath].push(oItem);
				}
			}
		}
32463
public S setBetn(int leftIndex, int rightIndex) {
		return set(Indexer.of(delegate.get()).between(leftIndex, rightIndex));
	}
437464
def insert(self, index, key, value):
        """"""
        if key in self.keyOrder:
            n = self.keyOrder.index(key)
            del self.keyOrder[n]
            if n < index:
                index -= 1
        self.keyOrder.insert(index, key)
        super(SortedDict, self).__setitem__(key, value)
1219252
def set_pointer(self, subseqs):
        """"""
        lines = Lines()
        for seq in subseqs:
            if seq.NDIM == 0:
                lines.extend(self.set_pointer0d(subseqs))
            break
        for seq in subseqs:
            if seq.NDIM == 1:
                lines.extend(self.alloc(subseqs))
                lines.extend(self.dealloc(subseqs))
                lines.extend(self.set_pointer1d(subseqs))
            break
        return lines
812738
private void moveIndexesToNextCombination()
    {
        for (int i = currentIndexes.length - 1, j = list.size() - 1; i >= 0; i--, j--)
        {
            if (currentIndexes[i] != j)
            {
                currentIndexes[i]++;
                for (int k = i + 1; k < currentIndexes.length; k++)
                {
                    currentIndexes[k] = currentIndexes[k - 1] + 1;
                }
                return;
            }
        }
        // otherwise, we are all done:
        currentIndexes = null;
    }
744702
public static final Mem byte_ptr(Register base, Register index, int shift, long disp) {
        return _ptr_build(base, index, shift, disp, SIZE_BYTE);
    }
378015
def __save(self, b):
        '''
            
        '''
        newbufferidx = (self.__bufferidx + len(b))
        self.__buffer[self.__bufferidx:newbufferidx] = b
        #update buffer index
        self.__bufferidx = newbufferidx
314240
void setPoint(int index, Point p) {
        if (index >= pointCount) {
            throw new IndexOutOfBoundsException();
        }
        p.copyTo(points[index]);
    }
1038427
public static void swap(byte[] byteArray, int index1, int index2) {
        TrivialSwap.swap(byteArray, index1, byteArray, index2);
    }