Skip to content

Commit 38ad66c

Browse files
update hash #2579
Signed-off-by: Nikolaj Bjorner <[email protected]>
1 parent 1203af8 commit 38ad66c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/util/mpq.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -521,7 +521,7 @@ class mpq_manager : public mpz_manager<SYNCH> {
521521

522522
static unsigned hash(mpz const & a) { return mpz_manager<SYNCH>::hash(a); }
523523

524-
static unsigned hash(mpq const & a) { return hash(a.m_num); }
524+
static unsigned hash(mpq const & a) { return hash(a.m_num) + 3*hash(a.m_den); }
525525

526526
bool eq(mpz const & a, mpz const & b) { return mpz_manager<SYNCH>::eq(a, b); }
527527

0 commit comments

Comments
 (0)