code: def _locals(self, d):
          
  
          if not d:
              return self
          c = self._copy()
          c._data.update(d)
          return c
docs: Create a new :class:`.Context` with a copy of this
          :class:`.Context`'s current state,
          updated with the given dictionary.
  
          The :attr:`.Context.kwargs` collection remains
          unaffected.