Patch to tinfo{,2}.cc

Jason Merrill jason@cygnus.com
Thu Apr 6 15:13:00 GMT 2000


So they build with -fno-builtin.

2000-04-06  Jason Merrill  <jason@yorick.cygnus.com>

	* tinfo.cc (operator=): Use __builtin_strcmp.
	* tinfo2.cc (before): Likewise.

Index: tinfo.cc
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cp/tinfo.cc,v
retrieving revision 1.21
diff -c -p -r1.21 tinfo.cc
*** tinfo.cc	2000/04/04 18:13:21	1.21
--- tinfo.cc	2000/04/06 22:12:44
*************** convert_to_base (void *addr, bool is_vir
*** 66,72 ****
  bool std::type_info::
  operator== (const std::type_info& arg) const
  {
!   return (&arg == this) || (strcmp (name (), arg.name ()) == 0);
  }
  
  extern "C" void
--- 66,72 ----
  bool std::type_info::
  operator== (const std::type_info& arg) const
  {
!   return (&arg == this) || (__builtin_strcmp (name (), arg.name ()) == 0);
  }
  
  extern "C" void
Index: tinfo2.cc
===================================================================
RCS file: /cvs/gcc/egcs/gcc/cp/tinfo2.cc,v
retrieving revision 1.18
diff -c -p -r1.18 tinfo2.cc
*** tinfo2.cc	2000/03/21 16:12:24	1.18
--- tinfo2.cc	2000/04/06 22:12:44
*************** using std::type_info;
*** 35,41 ****
  bool
  type_info::before (const type_info &arg) const
  {
!   return strcmp (name (), arg.name ()) < 0;
  }
  
  // type info for pointer type.
--- 35,41 ----
  bool
  type_info::before (const type_info &arg) const
  {
!   return __builtin_strcmp (name (), arg.name ()) < 0;
  }
  
  // type info for pointer type.


More information about the Gcc-patches mailing list