irgmod: Pass the new inputs to turn_into_tuple() instead of initialising them with...
[libfirm] / ir / ident / ident.c
index 4633ebd..8a23dfa 100644 (file)
@@ -21,7 +21,6 @@
  * @file
  * @brief     Hash table to store names.
  * @author    Goetz Lindenmaier
- * @version   $Id$
  */
 #include "config.h"
 
@@ -47,7 +46,7 @@ void init_ident(void)
 
 ident *new_id_from_chars(const char *str, size_t len)
 {
-       unsigned hash   = HASH_STR(str, len);
+       unsigned hash   = hash_data((const unsigned char*)str, len);
        ident   *result = (ident*) set_hinsert0(id_set, str, len, hash);
        return result;
 }
@@ -81,7 +80,7 @@ int id_is_prefix(ident *prefix, ident *id)
        size_t prefix_len = get_id_strlen(prefix);
        if (prefix_len > get_id_strlen(id))
                return 0;
-       return 0 == memcmp(get_id_str(prefix), get_id_str(id), prefix_len);
+       return 0 == memcmp(get_id_str(prefix), get_id_str(id), prefix_len);
 }
 
 int id_is_suffix(ident *suffix, ident *id)