[PATCH]: Fix problematic -Wcast-qual cases using new CONST_CAST macro

Mark Mitchell mark@codesourcery.com
Mon Aug 6 00:19:00 GMT 2007


Gabriel Dos Reis wrote:

> | Richard, do you have any remaining objections to this patch?
> | http://gcc.gnu.org/ml/gcc-patches/2007-07/msg01993.html

I'm not very keen on the use of a union here, just as a way to outwit
our own warning machinery.  For grep-ability, just using CONST_CAST with
a definition that is a traditional C-style cast, would work fine.  Or,
can we go through an inline function, with warnings disabled on the
inline function?

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713



More information about the Gcc-patches mailing list