NOTE: uncertain future
1459
long[] toLongArray() {
		// create array through an aligned copy
		BitVector copy = alignedCopy();
		long[] longs = copy.bits;
		int length = longs.length;
		if (length == 0) return longs;
		// reverse the array
		for (int i = 0, mid = length >> 1, j = length - 1; i < mid; i++, j--) {
			long t = longs[i];
			longs[i] = longs[j];
			longs[j] = t;
		}
		// mask off top bits in case copy was produced via clone
		final long mask = -1L >>> (ADDRESS_SIZE - copy.finish & ADDRESS_MASK);
		longs[0] &= mask;
		// return the result
		return longs;
	}
2034
def _folder_item_uncertainty(self, analysis_brain, item):
        

        item["Uncertainty"] = ""

        if not self.has_permission(ViewResults, analysis_brain):
            return

        result = analysis_brain.getResult

        obj = self.get_object(analysis_brain)
        formatted = format_uncertainty(obj, result, decimalmark=self.dmk,
                                       sciformat=int(self.scinot))
        if formatted:
            item["Uncertainty"] = formatted
        else:
            item["Uncertainty"] = obj.getUncertainty(result)

        if self.is_uncertainty_edition_allowed(analysis_brain):
            item["allow_edit"].append("Uncertainty")
566907
private boolean speculateFullAnnotation() {
        state.backtracking++;
        int start = input.mark();
        try {
            exprParser.fullAnnotation( null );
        } catch ( RecognitionException re ) {
            System.err.println( "impossible: " + re );
            re.printStackTrace();
        }
        boolean success = ! state.failed;
        input.rewind( start );
        state.backtracking--;
        state.failed = false;
        return success;

    }
39551
def couldChangeLane(self, vehID, direction):
        
        state = self.getLaneChangeState(vehID, direction)[0]
        return state != tc.LCA_UNKNOWN and (state & tc.LCA_BLOCKED == 0)
409782
function delay(timeout, value) {
        if (timeout < 0) {
            return value;
        }

        var future = new Future();
        setTimeout(function () {
            future.resolve(value);
        }, timeout);
        return future;
    }
1062791
private void pessimisticGetNext(
                                   DeleteStack    stack)
    {
        synchronized(_index)
        {
            internalGetNext(stack, _index.vno(), _index.xno());
            _pessimisticGetNexts++;
        }
    }
879322
def if_stale?(record, options = {})
      if stale?(StaleOptions.create(record, options))
        block_given? ? yield(record) : true
      end
    end
153029
@Override
    public boolean isDone() {
        for (Future<FUTURE_TYPE> future : futureList) {
            if (!future.isDone()) {
                return false;
            }
        }
        return true;
    }
1218755
@Override
  public boolean isFuture()
  {
    ResultChain<T> result = _result;

    return result.isFuture() && method().isDirect();
  }
369466
function maybe (options) {
  if (Math.round(Math.random())) {
    return options.fn(this);
  } else {
    return options.inverse(this);
  }
}
1360485
def next(self) -> Future:
        
        self._running_future = Future()

        if self._finished:
            self._return_result(self._finished.popleft())

        return self._running_future
827303
function(ta) {
				var fm = this.fm,
					dfrd = $(ta).data('dfrd');
				if (dfrd && dfrd.state() === 'pending') {
					dfrd.reject();
				}
			}
697021
def _imply_options(self):
        '''
        
        '''
        self.no_upload = self.no_upload or self.to_stdout or self.offline
        self.auto_update = self.auto_update and not self.offline
        if (self.analyze_container or
           self.analyze_file or
           self.analyze_mountpoint or
           self.analyze_image_id):
            self.analyze_container = True
        self.to_json = self.to_json or self.analyze_container
        self.register = (self.register or self.reregister) and not self.offline
        self.keep_archive = self.keep_archive or self.no_upload
        if self.payload:
            self.legacy_upload = False
404012
def potential_next(current, base)
      candidate = super(current, base)
      return candidate if (base.year - candidate.year).to_i % @interval == 0

      years = ((base.year - candidate.year).to_i % @interval)

      (candidate + years.years).beginning_of_year
    end
153016
def can_proceed(self):
        
        now = datetime.datetime.now()
        delta = datetime.timedelta(days=self.update_interval)
        return now >= self.last_update + delta
671033
def request_update(self):
        
        with self._lock:
            self._need_update = True
            if not self._future or self._future.is_done:
              self._future = Future()
            return self._future
1045929
def wait_for_futures(self):
        
        [future for future in futures.as_completed(self.futures)]
        self.futures = []