Commits

Michał Górny committed 494089c

PMPackage: support '!=' and hashing.

Comments (0)

Files changed (1)

gentoopm/basepm/pkg.py

 			return False
 		return self.id == other.id
 
+	def __ne__(self, other):
+		return not self.__eq__(other)
+
+	def __hash__(self):
+		return hash(self.id)
+
 	def __repr__(self):
 		return '%s(%s)' % (self.__class__.__name__, repr(self.id))