# HG changeset patch # User paulb@localhost.localdomain # Date 1180306306 -7200 # Node ID 0edf357fee41e67e2c0c9110a1579e687d20b97d # Parent 8dc39eefa7d27ff901c7c7cc5f0378593439e04f Changed the string representation of Structure objects. Added a tuple test. diff -r 8dc39eefa7d2 -r 0edf357fee41 simplify/simplified/data.py --- a/simplify/simplified/data.py Sun May 27 20:42:26 2007 +0200 +++ b/simplify/simplified/data.py Mon May 28 00:51:46 2007 +0200 @@ -174,9 +174,6 @@ else: raise ValueError, "__class__" - def __repr__(self): - return "Instance of type '%s'" % self.full_name() - def __eq__(self, other): # NOTE: Single instance: all instances are the same # NOTE: Multiple instances: all instances are different diff -r 8dc39eefa7d2 -r 0edf357fee41 simplify/simplified/utils.py --- a/simplify/simplified/utils.py Sun May 27 20:42:26 2007 +0200 +++ b/simplify/simplified/utils.py Mon May 28 00:51:46 2007 +0200 @@ -164,4 +164,7 @@ for name, value in kw.items(): setattr(self, name, value) + def __repr__(self): + return "%s '%s'" % (self.__class__.__name__, self.full_name()) + # vim: tabstop=4 expandtab shiftwidth=4 diff -r 8dc39eefa7d2 -r 0edf357fee41 tests/tuple.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/tests/tuple.py Mon May 28 00:51:46 2007 +0200 @@ -0,0 +1,2 @@ +t = (1, "2", 3) +a, b, c = t