This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: convert cpplib to use libiberty's hash tables


I applied this small fix, to reflect the recent change to the hashtable
interface.

2000-03-15  Jason Merrill  <jason@casey.cygnus.com>

	* cpphash.c (dump_hash_helper): Take the slot, not the element.

Index: cpphash.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cpphash.c,v
retrieving revision 1.57
diff -c -p -r1.57 cpphash.c
*** cpphash.c	2000/03/15 18:46:09	1.57
--- cpphash.c	2000/03/15 21:50:29
*************** Foundation, 59 Temple Place - Suite 330,
*** 33,39 ****
  static unsigned int hash_HASHNODE PARAMS ((const void *));
  static int eq_HASHNODE		  PARAMS ((const void *, const void *));
  static void del_HASHNODE	  PARAMS ((void *));
! static int dump_hash_helper	  PARAMS ((void *, void *));
  
  static int comp_def_part	 PARAMS ((int, U_CHAR *, int, U_CHAR *,
  					  int, int));
--- 33,39 ----
  static unsigned int hash_HASHNODE PARAMS ((const void *));
  static int eq_HASHNODE		  PARAMS ((const void *, const void *));
  static void del_HASHNODE	  PARAMS ((void *));
! static int dump_hash_helper	  PARAMS ((void **, void *));
  
  static int comp_def_part	 PARAMS ((int, U_CHAR *, int, U_CHAR *,
  					  int, int));
*************** _cpp_dump_definition (pfile, sym, len, d
*** 1722,1731 ****
  /* Dump out the hash table.  */
  static int
  dump_hash_helper (h, p)
!      void *h;
       void *p;
  {
!   HASHNODE *hp = (HASHNODE *)h;
    cpp_reader *pfile = (cpp_reader *)p;
  
    if (hp->type == T_MACRO)
--- 1722,1731 ----
  /* Dump out the hash table.  */
  static int
  dump_hash_helper (h, p)
!      void **h;
       void *p;
  {
!   HASHNODE *hp = (HASHNODE *)*h;
    cpp_reader *pfile = (cpp_reader *)p;
  
    if (hp->type == T_MACRO)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]