TODO faster and less new()
7185
public Number deserializeNumber(String s) {
		if(s.indexOf('.') >= 0 || s.indexOf('e') >= 0 || s.indexOf('E') >= 0) {
			return Double.valueOf(s);
		} else {
			Long l = Long.valueOf(s);
			if(l > Integer.MAX_VALUE || l <Integer.MIN_VALUE) {
				return l;
			} else {
				return new Integer(l.intValue());
			}
		}
	}
1058597
function () {
        while (this.head !== null) {
            var temp = this.head;
            this.head = this.head.next();   // use next() the instead of "_next", otherwise it will loop forever
            temp._list = null;
            temp._next = null;
            temp._prev = null;
        }

        this.head = null;
        this.size = 0;
    }
682851
function createTodo(state: State, text: ?string): State {
  if (!text) {
    return state;
  }
  var newTodo = new Todo(text);
  return state.set(newTodo.id, newTodo);
}
586911
def newnext(iterator, default=_SENTINEL):
    

    # args = []
    # if default is not _SENTINEL:
    #     args.append(default)
    try:
        try:
            return iterator.__next__()
        except AttributeError:
            try:
                return iterator.next()
            except AttributeError:
                raise TypeError("'{0}' object is not an iterator".format(
                                           iterator.__class__.__name__))
    except StopIteration as e:
        if default is _SENTINEL:
            raise e
        else:
            return default
1182339
function shallowCopy(t) {
  if (Array.isArray(t)) {
    return [...t];
  } else if (t && typeof t === 'object') {
    return Object.assign(new t.constructor(), t);
  }
  return t;
}
613728
function TodoList(props, context) {
	const { todos, ui } = props;
	const visibleTodos = ui.visibleTodos();

	if (todos.length === 0) {
		return <p className="noItems">What do you want to do today?</p>
	} else if (visibleTodos.length === 0) {
		return <p className="noItems">No items are { ui.filter }</p>
	}

	return <div>
		{
			visibleTodos.map( t => <TodoItem key={ t.$().pid() } todo={ t } todos={ todos } /> )
		}
		</div>
}
867937
function( object, callback, args ) {
		var name, i = 0, length = object.length;

		if ( args ) {
			if ( length === undefined ) {
				for ( name in object )
					if ( callback.apply( object[ name ], args ) === false )
						break;
			} else
				for ( ; i < length; )
					if ( callback.apply( object[ i++ ], args ) === false )
						break;

		// A special, fast, case for the most common use of each
		} else {
			if ( length === undefined ) {
				for ( name in object )
					if ( callback.call( object[ name ], name, object[ name ] ) === false )
						break;
			} else
				for ( var value = object[0];
					i < length && callback.call( value, i, value ) !== false; value = object[++i] ){}
		}

		return object;
	}
723006
function NextTick(method) {
      return function (target, key, descriptor) {
          var original = descriptor.value;
          descriptor.value = function emitter() {
              var args = [];
              for (var _i = 0; _i < arguments.length; _i++) {
                  args[_i] = arguments[_i];
              }
              if (original.apply(this, args) !== false)
                  if (typeof this[method] === 'function') {
                      this.$nextTick(this[method]);
                  }
                  else {
                      throw new TypeError('must be a method name');
                  }
          };
      };
  }
598755
def new(cls, variable, **kwargs):
        """"""
        return cls.array2mask(numpy.full(variable.shape, True))
557900
function update() {
  for (var
    tmp,
    promise = false,
    updates = this.updates,
    template = this.chunks,
    out = [template[0]],
    i = 1,
    length = arguments.length;
    i < length; i++
  ) {
    tmp = arguments[i];
    if (
      (typeof tmp === 'object' && tmp !== null)
      &&
      (typeof tmp.then === 'function' || 'placeholder' in tmp)
    ) {
      promise = true;
      out.push(
        ('placeholder' in tmp ? invokeAtDistance(tmp, false) : tmp)
          .then(updates[i - 1]),
        template[i]
      );
    } else {
      out.push(updates[i - 1](tmp), template[i]);
    }
  }
  return promise ? Promise.all(out).then(asBuffer) : asBuffer(out);
}
1204303
function shallowCopy(t) {
  if (Array.isArray(t)) {
    return [].concat(_toConsumableArray(t));
  } else if (t && (typeof t === 'undefined' ? 'undefined' : _typeof(t)) === 'object') {
    return Object.assign(new t.constructor(), t);
  }
  return t;
}
567248
function (keys) {
    var Parent = this.constructor;
    var opts = lazy.clone(this.options);
    var res = new Parent(opts);

    lazy.omit(this, keys, function (val, key) {
      res[key] = lazy.clone(val);
    });
    return res;
  }
849754
def new(cls, nsptagname, val):
        
        elm = OxmlElement(nsptagname)
        elm.val = val
        return elm
1121855
function (id, callback) {
        var todos = data.todos;

        for (var i = 0; i < todos.length; i++) {
          if (todos[i].id == id) {
            todos.splice(i, 1);
            break;
          }
        }

        flush();
        callback.call(undefined, data.todos);
      }
640134
def new(cls, func, args, mon, count=0):
        
        try:
            with mon:
                val = func(*args)
        except StopIteration:
            res = Result(None, mon, msg='TASK_ENDED')
        except Exception:
            _etype, exc, tb = sys.exc_info()
            res = Result(exc, mon, ''.join(traceback.format_tb(tb)),
                         count=count)
        else:
            res = Result(val, mon, count=count)
        return res
1323303
public long getAndSet(T obj, long newValue) {
        long prev;
        do {
            prev = get(obj);
        } while (!compareAndSet(obj, prev, newValue));
        return prev;
    }
1156089
@SafeVarargs
	public static <T> T[] append(T[] buffer, T... newElements) {
		if(isEmpty(buffer)) {
			return newElements;
		}
		return insert(buffer, buffer.length, newElements);
	}