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]
Other format: [Raw text]

Re: PATCH: abstract over necessary casts for obstack_finish


> libiberty/
> 2005-06-06  Gabriel Dos Reis  <gdr@integrable-solutions.net>
> 
> 	* libiberty.h (XOBFINISH): New.

This part is fine, although it doesn't buy you much savings on typing
;-)

> Index: include/libiberty.h
> ===================================================================
> RCS file: /cvs/gcc/gcc/include/libiberty.h,v
> retrieving revision 1.58
> diff -u -r1.58 libiberty.h
> --- include/libiberty.h	2 Jun 2005 02:01:03 -0000	1.58
> +++ include/libiberty.h	6 Jun 2005 18:33:50 -0000
> @@ -326,7 +326,7 @@
>  /* Type-safe obstack allocator.  */
>  
>  #define XOBNEW(O, T)		((T *) obstack_alloc ((O), sizeof (T)))
> -
> +#define XOBFINISH(O, T)         ((T) obstack_finish ((O)))
>  
>  /* hex character manipulation routines */


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