ensures structure is dirty and at pos newIndex and writable at level 0
763010
public void gotoPosWritable1(int oldIndex, int newIndex, int xor) {
        if (xor < (1 << 5)) { // level = 0
            display0 = copyOf(display0);
        } else if (xor < (1 << 10)) { // level = 1
            display1 = copyOf(display1);
            display1[(oldIndex >> 5) & 31] = display0;
            display0 = nullSlotAndCopy(display1, (newIndex >> 5) & 31);
        } else if (xor < (1 << 15)) { // level = 2
            display1 = copyOf(display1);
            display2 = copyOf(display2);
            display1[(oldIndex >> 5) & 31] = display0;
            display2[(oldIndex >> 10) & 31] = display1;
            display1 = nullSlotAndCopy(display2, (newIndex >> 10) & 31);
            display0 = nullSlotAndCopy(display1, (newIndex >> 5) & 31);
        } else if (xor < (1 << 20)) { // level = 3
            display1 = copyOf(display1);
            display2 = copyOf(display2);
            display3 = copyOf(display3);
            display1[(oldIndex >> 5) & 31] = display0;
            display2[(oldIndex >> 10) & 31] = display1;
            display3[(oldIndex >> 15) & 31] = display2;
            display2 = nullSlotAndCopy(display3, (newIndex >> 15) & 31);
            display1 = nullSlotAndCopy(display2, (newIndex >> 10) & 31);
            display0 = nullSlotAndCopy(display1, (newIndex >> 5) & 31);
        } else if (xor < (1 << 25)) { // level = 4
            display1 = copyOf(display1);
            display2 = copyOf(display2);
            display3 = copyOf(display3);
            display4 = copyOf(display4);
            display1[(oldIndex >> 5) & 31] = display0;
            display2[(oldIndex >> 10) & 31] = display1;
            display3[(oldIndex >> 15) & 31] = display2;
            display4[(oldIndex >> 20) & 31] = display3;
            display3 = nullSlotAndCopy(display4, (newIndex >> 20) & 31);
            display2 = nullSlotAndCopy(display3, (newIndex >> 15) & 31);
            display1 = nullSlotAndCopy(display2, (newIndex >> 10) & 31);
            display0 = nullSlotAndCopy(display1, (newIndex >> 5) & 31);
        } else if (xor < (1 << 30)) { // level = 5
            display1 = copyOf(display1);
            display2 = copyOf(display2);
            display3 = copyOf(display3);
            display4 = copyOf(display4);
            display5 = copyOf(display5);
            display1[(oldIndex >> 5) & 31] = display0;
            display2[(oldIndex >> 10) & 31] = display1;
            display3[(oldIndex >> 15) & 31] = display2;
            display4[(oldIndex >> 20) & 31] = display3;
            display5[(oldIndex >> 25) & 31] = display4;
            display4 = nullSlotAndCopy(display5, (newIndex >> 25) & 31);
            display3 = nullSlotAndCopy(display4, (newIndex >> 20) & 31);
            display2 = nullSlotAndCopy(display3, (newIndex >> 15) & 31);
            display1 = nullSlotAndCopy(display2, (newIndex >> 10) & 31);
            display0 = nullSlotAndCopy(display1, (newIndex >> 5) & 31);
        } else { // level = 6
            throw new IllegalArgumentException();
        }
    }
15672
function write(token, enc, next) {
    var type = token[0], buf = token[1];
    
    if(('rule_start' === type || 'atrule_start' === type))
      depth++;
    if(depth > 0 && !current)
      current = {location: [line, column], buffers:[]};
    if('rule_end' === type || 'atrule_end' === type)
      depth--;
    
    if(current) {
      current.buffers.push(buf);
      if(depth === 0) pushRule.call(this);
    }
    
    updatePosition(buf);
    next();
  }
33221
def index(self, index):
        
        if self._index != index:
            self._dirty = True
        self._index = index
1080825
protected function _dirty()
    {
        $this->_dirty = true;

        if ($this->_iterator && $this->_valueBinder) {
            $this->getValueBinder()->reset();
        }
    }
141654
function(parentValue, nameIndex) {

                                            if (nameIndex > defaultPropertyDepth) {
                                                defaultObserve = currentObserve;
                                                defaultReads = currentReads;
                                                defaultPropertyDepth = nameIndex;
                                                defaultScope = scope;

                                                defaultComputeReadings = can.__clearReading();
                                            }
                                        }
982025
private void percolateDown(int pos) {
    int p = pos;
    int y = this.heap.get(p);
    while (left(p) < this.heap.size()) {
      int child = right(p) < this.heap.size() && this.s.lt(this.heap.get(right(p)), this.heap.get(left(p))) ? right(p) : left(p);
      if (!this.s.lt(this.heap.get(child), y))
        break;
      this.heap.set(p, this.heap.get(child));
      this.indices.set(this.heap.get(p), p);
      p = child;
    }
    this.heap.set(p, y);
    this.indices.set(y, p);
  }
1076082
def flushIndexes(cls) :
		""
		con = RabaConnection(cls._raba_namespace)
		for idx in cls.getIndexes() :
			con.dropIndexByName(idx[1])
819696
def _standardize(structure):
    '''
    
    '''
    def mutating_helper(structure):
        if isinstance(structure, list):
            structure.sort(key=_id_or_key)
            for each in structure:
                mutating_helper(each)
        elif isinstance(structure, dict):
            structure = dict(structure)
            for k, v in six.iteritems(structure):
                mutating_helper(k)
                mutating_helper(v)

    new_structure = copy.deepcopy(structure)
    mutating_helper(new_structure)
    return new_structure
308828
def SetRaw(self, name, value):
    """"""
    if self.writeback is None:
      logging.warning("Attempting to modify a read only config object.")
    if name in self.constants:
      raise ConstModificationError(
          "Attempting to modify constant value %s" % name)

    self.writeback_data[name] = value
    self.FlushCache()
880504
public void writeToIndex(Object object) {
        Assert.notNull(object, "no object data given");

        lazyInitWriting();
        BytesRef serialized = bulkEntryWriter.writeBulkEntry(object);
        if (serialized != null) {
            doWriteToIndex(serialized);
        }
    }
964580
def clean_indexes(self):
        
        self.sort()
        for index, item in enumerate(self):
            item.index = index + 1
1103463
void reset()
  {
    _deleteNode = null;
    _deleteIndex = 0;
    _targetNode = null;
    _targetIndex = 0;
    _type = NONE;
    _notFound = true;
  }
910128
private T retain0(T instance, final int increment, final int rawIncrement) {
        int oldRef = updater().getAndAdd(instance, rawIncrement);
        if (oldRef != 2 && oldRef != 4 && (oldRef & 1) != 0) {
            throw new IllegalReferenceCountException(0, increment);
        }
        // don't pass 0!
        if ((oldRef <= 0 && oldRef + rawIncrement >= 0)
                || (oldRef >= 0 && oldRef + rawIncrement < oldRef)) {
            // overflow case
            updater().getAndAdd(instance, -rawIncrement);
            throw new IllegalReferenceCountException(realRefCnt(oldRef), increment);
        }
        return instance;
    }
322564
private void cleanRightEdge(int cutIndex) {
        // we're actually sitting one block left if cutIndex lies on a block boundary
        // this means that we'll end up erasing the whole block!!

        if (cutIndex <= (1 << 5)) {
            zeroRight(pointer.display0, cutIndex);
        } else if (cutIndex <= (1 << 10)) {
            zeroRight(pointer.display0, ((cutIndex - 1) & 0x1f) + 1);
            pointer.display1 = copyLeft(pointer.display1, (cutIndex >>> 5));
        } else if (cutIndex <= (1 << 15)) {
            zeroRight(pointer.display0, ((cutIndex - 1) & 0x1f) + 1);
            pointer.display1 = copyLeft(pointer.display1, (((cutIndex - 1) >>> 5) & 0x1f) + 1);
            pointer.display2 = copyLeft(pointer.display2, (cutIndex >>> 10));
        } else if (cutIndex <= (1 << 20)) {
            zeroRight(pointer.display0, ((cutIndex - 1) & 0x1f) + 1);
            pointer.display1 = copyLeft(pointer.display1, (((cutIndex - 1) >>> 5) & 0x1f) + 1);
            pointer.display2 = copyLeft(pointer.display2, (((cutIndex - 1) >>> 10) & 0x1f) + 1);
            pointer.display3 = copyLeft(pointer.display3, (cutIndex >>> 15));
        } else if (cutIndex <= (1 << 25)) {
            zeroRight(pointer.display0, ((cutIndex - 1) & 0x1f) + 1);
            pointer.display1 = copyLeft(pointer.display1, (((cutIndex - 1) >>> 5) & 0x1f) + 1);
            pointer.display2 = copyLeft(pointer.display2, (((cutIndex - 1) >>> 10) & 0x1f) + 1);
            pointer.display3 = copyLeft(pointer.display3, (((cutIndex - 1) >>> 15) & 0x1f) + 1);
            pointer.display4 = copyLeft(pointer.display4, (cutIndex >>> 20));
        } else if (cutIndex <= (1 << 30)) {
            zeroRight(pointer.display0, ((cutIndex - 1) & 0x1f) + 1);
            pointer.display1 = copyLeft(pointer.display1, (((cutIndex - 1) >>> 5) & 0x1f) + 1);
            pointer.display2 = copyLeft(pointer.display2, (((cutIndex - 1) >>> 10) & 0x1f) + 1);
            pointer.display3 = copyLeft(pointer.display3, (((cutIndex - 1) >>> 15) & 0x1f) + 1);
            pointer.display4 = copyLeft(pointer.display4, (((cutIndex - 1) >>> 20) & 0x1f) + 1);
            pointer.display5 = copyLeft(pointer.display5, (cutIndex >>> 25));
        } else {
            throw new IllegalArgumentException();
        }
    }
917488
private void cleanLeftEdge(int cutIndex) {
        if (cutIndex < (1 << 5)) {
            zeroLeft(pointer.display0, cutIndex);
        } else if (cutIndex < (1 << 10)) {
            zeroLeft(pointer.display0, cutIndex & 0x1f);
            pointer.display1 = copyRight(pointer.display1, (cutIndex >>> 5));
        } else if (cutIndex < (1 << 15)) {
            zeroLeft(pointer.display0, cutIndex & 0x1f);
            pointer.display1 = copyRight(pointer.display1, (cutIndex >>> 5) & 0x1f);
            pointer.display2 = copyRight(pointer.display2, (cutIndex >>> 10));
        } else if (cutIndex < (1 << 20)) {
            zeroLeft(pointer.display0, cutIndex & 0x1f);
            pointer.display1 = copyRight(pointer.display1, (cutIndex >>> 5) & 0x1f);
            pointer.display2 = copyRight(pointer.display2, (cutIndex >>> 10) & 0x1f);
            pointer.display3 = copyRight(pointer.display3, (cutIndex >>> 15));
        } else if (cutIndex < (1 << 25)) {
            zeroLeft(pointer.display0, cutIndex & 0x1f);
            pointer.display1 = copyRight(pointer.display1, (cutIndex >>> 5) & 0x1f);
            pointer.display2 = copyRight(pointer.display2, (cutIndex >>> 10) & 0x1f);
            pointer.display3 = copyRight(pointer.display3, (cutIndex >>> 15) & 0x1f);
            pointer.display4 = copyRight(pointer.display4, (cutIndex >>> 20));
        } else if (cutIndex < (1 << 30)) {
            zeroLeft(pointer.display0, cutIndex & 0x1f);
            pointer.display1 = copyRight(pointer.display1, (cutIndex >>> 5) & 0x1f);
            pointer.display2 = copyRight(pointer.display2, (cutIndex >>> 10) & 0x1f);
            pointer.display3 = copyRight(pointer.display3, (cutIndex >>> 15) & 0x1f);
            pointer.display4 = copyRight(pointer.display4, (cutIndex >>> 20) & 0x1f);
            pointer.display5 = copyRight(pointer.display5, (cutIndex >>> 25));
        } else {
            throw new IllegalArgumentException();
        }
    }
210002
def __flushLevel(self, level):
        """"""
        objectsCount = len(self.objectsStack)

        while objectsCount > level:
            lastIndex = objectsCount - 1
            if lastIndex == 0:
                # We have exactly one element in the stack
                if self.objectsStack[0].__class__.__name__ == "Class":
                    self.classes.append(self.objectsStack[0])
                else:
                    self.functions.append(self.objectsStack[0])
                self.objectsStack = []
                break

            # Append to the previous level
            if self.objectsStack[lastIndex].__class__.__name__ == "Class":
                self.objectsStack[lastIndex - 1].classes. \
                    append(self.objectsStack[lastIndex])
            else:
                self.objectsStack[lastIndex - 1].functions. \
                    append(self.objectsStack[lastIndex])

            del self.objectsStack[lastIndex]
            objectsCount -= 1
62505
void flush() {
		internalLock.writeLock().lock();
		flushLock.lock();
		try {
			if (isNew || modifiedBy.size() > 0) {
				VanillaDb.logMgr().flush(lastLsn);
				contents.write(blk);
				modifiedBy.clear();
				isNew = false;
			}
		} finally {
			flushLock.unlock();
			internalLock.writeLock().unlock();
		}
	}