##// END OF EJS Templates
basefilectx: move __repr__ from filectx...
Sean Farley -
r19580:e86a594a default
parent child Browse files
Show More
@@ -458,6 +458,9 b' class basefilectx(object):'
458 def __str__(self):
458 def __str__(self):
459 return "%s@%s" % (self.path(), short(self.node()))
459 return "%s@%s" % (self.path(), short(self.node()))
460
460
461 def __repr__(self):
462 return "<%s %s>" % (type(self).__name__, str(self))
463
461 class filectx(basefilectx):
464 class filectx(basefilectx):
462 """A filecontext object makes access to data related to a particular
465 """A filecontext object makes access to data related to a particular
463 filerevision convenient."""
466 filerevision convenient."""
@@ -507,9 +510,6 b' class filectx(basefilectx):'
507 # considered when solving linkrev issue are on the table.
510 # considered when solving linkrev issue are on the table.
508 return changectx(self._repo.unfiltered(), self._changeid)
511 return changectx(self._repo.unfiltered(), self._changeid)
509
512
510 def __repr__(self):
511 return "<filectx %s>" % str(self)
512
513 def __hash__(self):
513 def __hash__(self):
514 try:
514 try:
515 return hash((self._path, self._filenode))
515 return hash((self._path, self._filenode))
General Comments 0
You need to be logged in to leave comments. Login now