From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1QlkcC-0005pN-71 for garchives@archives.gentoo.org; Tue, 26 Jul 2011 16:36:16 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 6A93F21C097; Tue, 26 Jul 2011 16:36:08 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 3D61021C097 for ; Tue, 26 Jul 2011 16:36:08 +0000 (UTC) Received: from pelican.gentoo.org (unknown [66.219.59.40]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BFF382AC016 for ; Tue, 26 Jul 2011 16:36:07 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by pelican.gentoo.org (Postfix) with ESMTP id 6CDB080042 for ; Tue, 26 Jul 2011 16:36:06 +0000 (UTC) From: "Michał Górny" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Michał Górny" Message-ID: Subject: [gentoo-commits] proj/gentoopm:master commit in: gentoopm/basepm/ X-VCS-Repository: proj/gentoopm X-VCS-Files: gentoopm/basepm/depend.py X-VCS-Directories: gentoopm/basepm/ X-VCS-Committer: mgorny X-VCS-Committer-Name: Michał Górny X-VCS-Revision: da059384996e9657d166673a3edeabcdde9199d2 Date: Tue, 26 Jul 2011 16:36:06 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: X-Archives-Hash: 4c2b96e9f309563ab4c79316f4fec6a4 commit: da059384996e9657d166673a3edeabcdde9199d2 Author: Micha=C5=82 G=C3=B3rny gentoo org> AuthorDate: Tue Jul 26 16:36:51 2011 +0000 Commit: Micha=C5=82 G=C3=B3rny gentoo org> CommitDate: Tue Jul 26 16:36:51 2011 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/gentoopm.git;= a=3Dcommit;h=3Dda059384 Support __repr__ on depspecs. --- gentoopm/basepm/depend.py | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/gentoopm/basepm/depend.py b/gentoopm/basepm/depend.py index 8d7005d..262a010 100644 --- a/gentoopm/basepm/depend.py +++ b/gentoopm/basepm/depend.py @@ -30,6 +30,12 @@ class PMBaseDep(ABCObject): """ pass =20 + def __repr__(self): + l =3D ['\n'.join(['\t%s' % x for x in repr(d).splitlines()]) + for d in self] + return '%s(\n%s)' % (self.__class__.__name__, + ',\n'.join(l)) + class PMUncondBaseDep(PMBaseDep): def __init__(self, parent): self._parent =3D parent