This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Fix incorrect discriminator assignment.
- From: Cary Coutant <ccoutant at google dot com>
- To: Dehao Chen <dehao at google dot com>
- Cc: Richard Biener <richard dot guenther at gmail dot com>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Wed, 22 May 2013 09:40:12 -0700
- Subject: Re: [PATCH] Fix incorrect discriminator assignment.
- References: <CAO2gOZVtO8Ux9HdCaMuSSzS8Rxk2usyVDBo+ba9_ehT1POyF0w at mail dot gmail dot com> <CAHACq4qfVyzjRTO=Z+LVd++_RVZHzTomFDhtw2cRqC=F=G07Aw at mail dot gmail dot com> <CAFiYyc3qFuCy-SN5H1Ja0CQN5qEBH3zMPGeyAd+6gHCFL=cKtQ at mail dot gmail dot com> <CAO2gOZV-F17-Mm4KjvwkCgmGvfaRC8_sViiq9-_c6n=JAUYnwg at mail dot gmail dot com> <CAFiYyc0yTNr+-fqbj6SWbksdgUcOGzW=2V+kBjzdbMmqCZDQEQ at mail dot gmail dot com> <CAO2gOZV-SDTZ0WKrRTS-9N=ZJmSqm3oPDNzwmTDGxbboLJGE7g at mail dot gmail dot com>
@@ -105,7 +105,7 @@ struct locus_descrim_hasher : typed_free_remove <l
inline hashval_t
locus_descrim_hasher::hash (const value_type *item)
{
- return item->locus;
+ return LOCATION_LINE (item->locus);
}
/* Equality function for the locus-to-discriminator map. A and B
@@ -114,7 +114,7 @@ locus_descrim_hasher::hash (const value_type *item
inline bool
locus_descrim_hasher::equal (const value_type *a, const compare_type *b)
{
- return a->locus == b->locus;
+ return LOCATION_LINE (a->locus) == LOCATION_LINE (b->locus);
}
While you're in that part of the code, could you fix the spelling of
locus_descrim_hasher? Should be "locus_discrim_hasher".
-cary