Hello.

This is a regression that was introduced in r216127.
I tested the patch on ppc64le and I'm going to install it.

Martin

gcc/fortran/ChangeLog:

2018-10-30  Martin Liska  <mli...@suse.cz>

        * trans-decl.c (struct module_hasher): Call htab_hash_string
        for s->name and not for s.
---
 gcc/fortran/trans-decl.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)


diff --git a/gcc/fortran/trans-decl.c b/gcc/fortran/trans-decl.c
index 88f9f570725..83cbcd123fe 100644
--- a/gcc/fortran/trans-decl.c
+++ b/gcc/fortran/trans-decl.c
@@ -4825,7 +4825,11 @@ struct module_hasher : ggc_ptr_hash<module_htab_entry>
 {
   typedef const char *compare_type;
 
-  static hashval_t hash (module_htab_entry *s) { return htab_hash_string (s); }
+  static hashval_t hash (module_htab_entry *s)
+  {
+    return htab_hash_string (s->name);
+  }
+
   static bool
   equal (module_htab_entry *a, const char *b)
   {

Reply via email to