summaryrefslogtreecommitdiffstats
path: root/pym
diff options
context:
space:
mode:
authorBrian Harring <ferringb@gentoo.org>2005-12-19 12:21:54 +0000
committerBrian Harring <ferringb@gentoo.org>2005-12-19 12:21:54 +0000
commitdea579648ec7ec443256f0ddb993198d845bb842 (patch)
treed75c7912137294593a9cb623e9587e4345e4feb1 /pym
parent6d2e7a1c021e7cf80be317bd2dfd823a9406c03e (diff)
downloadportage-dea579648ec7ec443256f0ddb993198d845bb842.tar.gz
portage-dea579648ec7ec443256f0ddb993198d845bb842.tar.bz2
portage-dea579648ec7ec443256f0ddb993198d845bb842.zip
further type -> isinstance cleanup in dep crap
svn path=/main/trunk/; revision=2404
Diffstat (limited to 'pym')
-rw-r--r--pym/portage.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/pym/portage.py b/pym/portage.py
index c14e28c1c..a986aa553 100644
--- a/pym/portage.py
+++ b/pym/portage.py
@@ -3088,7 +3088,7 @@ def dep_opconvert(mysplit,myuse,mysettings):
#mismatched paren, error
return None
elif mysplit[mypos]=="||":
- if ((mypos + 1) >= len(mysplit)) or (not isinstance(mysplit[mypos+1], list)):
+ if mypos + 1 >= len(mysplit) or not isinstance(mysplit[mypos+1], list):
# || must be followed by paren'd list
return None
try:
@@ -3141,13 +3141,13 @@ def dep_opconvert(mysplit,myuse,mysettings):
#colon mode
if enabled:
#choose the first option
- if type(mysplit[mypos+1])==types.ListType:
+ if isinstance(mysplit[mypos + 1], list):
newsplit.append(dep_opconvert(mysplit[mypos+1],myuse,mysettings))
else:
newsplit.append(mysplit[mypos+1])
else:
#choose the alternate option
- if type(mysplit[mypos+1])==types.ListType:
+ if isinstance(mysplit[mypos + 1], list):
newsplit.append(dep_opconvert(mysplit[mypos+3],myuse,mysettings))
else:
newsplit.append(mysplit[mypos+3])
@@ -3155,7 +3155,7 @@ def dep_opconvert(mysplit,myuse,mysettings):
else:
#normal use mode
if enabled:
- if type(mysplit[mypos+1])==types.ListType:
+ if isinstance(mysplit[mypos + 1], list):
newsplit.append(dep_opconvert(mysplit[mypos+1],myuse,mysettings))
else:
newsplit.append(mysplit[mypos+1])