From: Arfrever Frehtes Taifersar Arahesis Date: Tue, 7 Jan 2014 23:40:39 +0000 (+0100) Subject: portage.versions.ververify(): Return an instance of bool (which is a subclass of... X-Git-Tag: fetch-refactor-v1~6 X-Git-Url: http://git.tremily.us/?p=portage.git;a=commitdiff_plain;h=3a2a504777054e69efb705afa94d8584105d9604 portage.versions.ververify(): Return an instance of bool (which is a subclass of int anyway) for better __repr__. --- diff --git a/pym/portage/versions.py b/pym/portage/versions.py index 3bfc388ea..615d52298 100644 --- a/pym/portage/versions.py +++ b/pym/portage/versions.py @@ -1,5 +1,5 @@ # versions.py -- core Portage functionality -# Copyright 1998-2013 Gentoo Foundation +# Copyright 1998-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 from __future__ import unicode_literals @@ -109,11 +109,11 @@ def _get_pv_re(eapi_attrs): def ververify(myver, silent=1): if ver_regexp.match(myver): - return 1 + return True else: if not silent: print(_("!!! syntax error in version: %s") % myver) - return 0 + return False def vercmp(ver1, ver2, silent=1): """