diff options
author | Sebastian Luther <SebastianLuther@gmx.de> | 2010-07-23 15:43:40 +0200 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2010-07-23 09:47:13 -0700 |
commit | 29825ae82a3a7c51be0b3312e74c9cb0288abbaa (patch) | |
tree | 3a1284914316a49e321074748706be080f11b5c5 | |
parent | 853bf94db3f6f40ee761833f57be94f6084af709 (diff) | |
download | portage-29825ae82a3a7c51be0b3312e74c9cb0288abbaa.tar.gz portage-29825ae82a3a7c51be0b3312e74c9cb0288abbaa.tar.bz2 portage-29825ae82a3a7c51be0b3312e74c9cb0288abbaa.zip |
portage.dep.isvalidatom(): Add support for atoms with wildcards
-rw-r--r-- | pym/portage/dep/__init__.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/pym/portage/dep/__init__.py b/pym/portage/dep/__init__.py index bd5cfcc86..c58a83e44 100644 --- a/pym/portage/dep/__init__.py +++ b/pym/portage/dep/__init__.py @@ -938,7 +938,7 @@ _atom_re = re.compile('^(?P<without_use>(?:' + '(?P<simple>' + _cp + '))(:' + _slot + ')?)(' + _use + ')?$', re.VERBOSE) _atom_wildcard_re = re.compile('(?P<simple>((' + _cat + '|\*)/(' + _pkg + '|\*)))$') -def isvalidatom(atom, allow_blockers=False): +def isvalidatom(atom, allow_blockers=False, allow_wildcard=False): """ Check to see if a depend atom is valid @@ -957,7 +957,7 @@ def isvalidatom(atom, allow_blockers=False): """ try: if not isinstance(atom, Atom): - atom = Atom(atom) + atom = Atom(atom, allow_wildcard=allow_wildcard) if not allow_blockers and atom.blocker: return False return True |