mirror of
https://git.launchpad.net/~ubuntu-release/britney/+git/britney2-ubuntu
synced 2025-03-26 10:21:12 +00:00
Hint: implement equality based on comparing string representations
This will work for "single package" hints, but should be extended to consider "easy foo/1 bar/1" and "easy bar/1 foo/1" to be equivalent. Signed-off-by: Adam D. Barratt <adam@adam-barratt.org.uk>
This commit is contained in:
parent
b76d9e189a
commit
f35342993c
3
hints.py
3
hints.py
@ -65,6 +65,9 @@ class Hint:
|
||||
def __str__(self):
|
||||
return self._hint
|
||||
|
||||
def __eq__(self, other):
|
||||
return str(self) == str(other)
|
||||
|
||||
@property
|
||||
def type(self):
|
||||
return self._type
|
||||
|
Loading…
x
Reference in New Issue
Block a user