From ff00dac71e9d1810f0d95d096132f76a2872df65 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sat, 27 Mar 2010 14:44:57 -0700 Subject: Implement __unicode__ for python2. --- pym/portage/proxy/objectproxy.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'pym/portage/proxy') diff --git a/pym/portage/proxy/objectproxy.py b/pym/portage/proxy/objectproxy.py index 9bcd6b43a..92b36d111 100644 --- a/pym/portage/proxy/objectproxy.py +++ b/pym/portage/proxy/objectproxy.py @@ -84,5 +84,8 @@ class ObjectProxy(object): if sys.hexversion < 0x3000000: __nonzero__ = __bool__ + def __unicode__(self): + return unicode(object.__getattribute__(self, '_get_target')()) + def __int__(self): return int(object.__getattribute__(self, '_get_target')()) -- cgit v1.2.3-1-g7c22