INNER CODE UNIT · Python

update

mahmoud/boltons · boltons/cacheutils.py:296

    def update(self, E=(), **F):
        # E and F are throwback names to the dict() __doc__
        with self._lock:
            setitem = self.__setitem__
            if E is not self:
                if callable(getattr(E, 'keys', None)):
                    for k in E.keys():
                        setitem(k, E[k])
                else:
                    for k, v in E:
                        setitem(k, v)
            for k in F:
                setitem(k, F[k])
            return

    def __eq__(self, other):
        with self._lock:
            if self is other:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…