From 27b5e425e16360f293d45722a8645f00326fabb8 Mon Sep 17 00:00:00 2001 From: Sebastian Luther Date: Wed, 11 Aug 2010 09:15:43 +0200 Subject: portage/cache/mappings.py: Remove deprecated functions --- pym/portage/cache/mappings.py | 25 ------------------------- 1 file changed, 25 deletions(-) diff --git a/pym/portage/cache/mappings.py b/pym/portage/cache/mappings.py index 0ef5c3ac6..60a918e01 100644 --- a/pym/portage/cache/mappings.py +++ b/pym/portage/cache/mappings.py @@ -6,7 +6,6 @@ __all__ = ["Mapping", "MutableMapping", "UserDict", "ProtectedDict", "LazyLoad", "slot_dict_class"] import sys -import warnings import weakref class Mapping(object): @@ -29,11 +28,6 @@ class Mapping(object): def keys(self): return list(self.__iter__()) - def has_key(self, key): - warnings.warn("portage.cache.mappings.Mapping.has_key() " + \ - "is deprecated, use the in operator instead", DeprecationWarning) - return key in self - def __contains__(self, key): try: value = self[key] @@ -268,12 +262,6 @@ class ProtectedDict(MutableMapping): def __contains__(self, key): return key in self.new or (key not in self.blacklist and key in self.orig) - def has_key(self, key): - warnings.warn("portage.cache.mapping.ProtectedDict.has_key() is" - " deprecated, use the in operator instead", - DeprecationWarning) - return key in self - if sys.hexversion >= 0x3000000: keys = __iter__ @@ -303,13 +291,6 @@ class LazyLoad(Mapping): self.pull = None return iter(self.d) - def has_key(self, key): - warnings.warn("portage.cache.mappings.LazyLoad.has_key() is " - "deprecated, use the in operator instead", - DeprecationWarning) - return key in self - - def __contains__(self, key): if key in self.d: return True @@ -454,12 +435,6 @@ def slot_dict_class(keys, prefix="_val_"): def __contains__(self, k): return hasattr(self, self._prefix + k) - def has_key(self, k): - warnings.warn("portage.cache.mappings.SlotDict.has_key()" + \ - " is deprecated, use the in operator instead", - DeprecationWarning) - return k in self - def pop(self, key, *args): if len(args) > 1: raise TypeError( -- cgit v1.2.3-1-g7c22