projects
/
portage.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
26447c4
)
Implement ExtendedAtomDict.copy().
author
Zac Medico
<zmedico@gentoo.org>
Thu, 2 Sep 2010 21:31:35 +0000
(14:31 -0700)
committer
Zac Medico
<zmedico@gentoo.org>
Thu, 2 Sep 2010 21:31:35 +0000
(14:31 -0700)
pym/portage/dep/__init__.py
patch
|
blob
|
history
diff --git
a/pym/portage/dep/__init__.py
b/pym/portage/dep/__init__.py
index 8e2b2ef49c9ea90c556bb919d7831115c1969e8b..7475d85920d5edb0679f1c4ff93a0af204841a69 100644
(file)
--- a/
pym/portage/dep/__init__.py
+++ b/
pym/portage/dep/__init__.py
@@
-1232,6
+1232,12
@@
class ExtendedAtomDict(portage.cache.mappings.MutableMapping):
self._normal = {}
self._value_class = value_class
+ def copy(self):
+ result = self.__class__(self._value_class)
+ result._extended.update(self._extended)
+ result._normal.update(self._normal)
+ return result
+
def __iter__(self):
for k in self._normal:
yield k