summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Dolbec <brian.dolbec@gmail.com>2011-01-29 02:11:18 -0800
committerZac Medico <zmedico@gentoo.org>2011-01-30 01:11:58 -0800
commit6b7177c92af62ee17200f118dcdcad35e50c7ade (patch)
tree97a1901860ef94a5b5715fc39f884855f39575be
parent6fbb1c1c70ba82a2a06531e69b9851bf01c42e12 (diff)
downloadportage-6b7177c92af62ee17200f118dcdcad35e50c7ade.tar.gz
portage-6b7177c92af62ee17200f118dcdcad35e50c7ade.tar.bz2
portage-6b7177c92af62ee17200f118dcdcad35e50c7ade.zip
optimize isHardMasked() a little more
-rw-r--r--pym/_emerge/Package.py7
1 files changed, 2 insertions, 5 deletions
diff --git a/pym/_emerge/Package.py b/pym/_emerge/Package.py
index e7302b351..96c76b965 100644
--- a/pym/_emerge/Package.py
+++ b/pym/_emerge/Package.py
@@ -263,17 +263,14 @@ class Package(Task):
pmask = []
if pmask:
# narrow pmask atoms down to the relevant repo
- n=[x for x in pmask if x.split('::')[-1] in [self.repo]]
+ n = [x for x in pmask if x.split('::')[-1] in [self.repo]]
# hopefully it is down to only 1 mask atom
#print "n =", n
#count = 0
hardmasked = set()
for x in n:
#expand the atom to matching available ebuilds
- m = self.root_config.trees['porttree'].dbapi.xmatch("match-all",x)
- #print "m =", m
- for n in m:
- hardmasked.update([n])
+ hardmasked.update(self.root_config.trees['porttree'].dbapi.xmatch("match-all",x))
#count += 1
#print "for x in n: loop count =", count, hardmasked
return self.cpv in hardmasked