Items to take precedence if their values are not None (never saved)
186916
def might_prefer(self, **items):
        ''''''
        self._overrides = dict((k, v) for (k, v) in items.items() if v is not None)
63382
def reserved(self, value):
        """"""
        self.bytearray[self._get_slicers(2)] = bytearray(c_uint16(value or 0))
59744
def get_and_set(self, value):
        '''
        
        '''
        with self._lock.exclusive:
            oldval = self._value
            self._value = value
            return oldval
217064
def _drop_none_values(dictionary: Dict) -> Dict:
    
    return {key: value for key, value in dictionary.items() if value is not None}
509946
def set_item(self,item):
        ""
        self.item = self.x.process_one(item)
        yield None
        self.item = None
283057
function prefix(value, prefix, ignored = []) {
	if (prefix === false) {
		return value;
	}

	if (ignored.includes(prefix)) {
		return toDashCase(value);
	}

	return prefix + '-' + toDashCase(value);
}
774179
def _missing_(cls, value):
        """"""
        if not (isinstance(value, int) and 0 <= value <= 65535):
            raise ValueError('%r is not a valid %s' % (value, cls.__name__))
        if 2 <= value <= 6:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 8 <= value <= 13:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 21 <= value <= 23:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 29 <= value <= 31:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 33 <= value <= 39:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 52 <= value <= 59:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 63 <= value <= 69:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 71 <= value <= 89:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 91 <= value <= 99:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 101 <= value <= 8191:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 8192 <= value <= 16383:
            # [RFC 7401]
            extend_enum(cls, 'Reserved for Private Use [%d]' % value, value)
            return cls(value)
        if 16385 <= value <= 40959:
            extend_enum(cls, 'Unassigned [%d]' % value, value)
            return cls(value)
        if 40960 <= value <= 65535:
            # [RFC 7401]
            extend_enum(cls, 'Reserved for Private Use [%d]' % value, value)
            return cls(value)
        super()._missing_(value)
477755
function( rules, priority, options ) {
			var args = [ this.findIndex( priority ), 0 ];

			for ( var i = 0, len = rules.length; i < len; i++ ) {
				args.push( {
					value: rules[ i ],
					priority: priority,
					options: options
				} );
			}

			this.rules.splice.apply( this.rules, args );
		}
803732
def _optional_list(value):
    ''''''
    if isinstance(value, str):
        return (value, )
    elif isinstance(value, list):
        return tuple(value)

    return None
786519
def priority(s):
    """"""
    # REZ: Previously this value was calculated in place many times which is
    #      expensive.  Do it once early.
    # REZ: Changed this to output a list, so that can nicely sort "validate"
    #      items by the sub-priority of their schema
    type_of_s = type(s)
    if type_of_s in (list, tuple, set, frozenset):
        return [ITERABLE]
    if type_of_s is dict:
        return [DICT]
    if issubclass(type_of_s, type):
        return [TYPE]
    if hasattr(s, 'validate'):
        p = [VALIDATOR]
        if hasattr(s, "_schema"):
            p.extend(priority(s._schema))
        return p
    if callable(s):
        return [CALLABLE]
    else:
        return [COMPARABLE]
1108062
def last(self, callback=None, default=None):
        
        if callback is not None:
            for val in reversed(self.items):
                if callback(val):
                    return val

            return value(default)

        if len(self.items) > 0:
            return self.items[-1]
        else:
            return default
1158990
function(items) {
            var hasRelativePositioning = hasNumberProperty(items, 'relativePosition');

            for(var i = 0; i < items.length; i++) {
                if(i == items.length - 1)
                    items[i].diffWithNextRelativePos = undefined;
                else
                    items[i].diffWithNextRelativePos = items[i + 1].relativePosition - items[i].relativePosition;
            }
        }
28972
def clean_inconcs(self):
        
        for item in self.data:
            if (item.inconclusive or item.get_verdict() == "unknown") and not item.retries_left > 0:
                return True
        return False
1192624
function(values, silent) {
			var items = $.isArray(values) ? values : [values];
			for (var i = 0, n = items.length; i < n; i++) {
				this.isPending = (i < n - 1);
				this.addItem(items[i], silent);
			}
		}
755435
def skip_redundant(iterable, skipset=None):
    
    if skipset is None:
        skipset = set()
    for item in iterable:
        if item not in skipset:
            skipset.add(item)
            yield item
159757
def _process_exlist(self, exc, raised):
        """"""
        if (not raised) or (raised and exc.endswith("*")):
            return exc[:-1] if exc.endswith("*") else exc
        return None
1215277
def _filter_none(items):
    """"""
    type_ = list if isinstance(items, list) else tuple
    return type_(filter(_not_none, items))