Re: [patch] const_cast to be replaced by str_unconst

Oswald Buddenhagen wrote:
whoops, this is exactly what you're talking about. :}
anyway, i don't think this extra warning would matter, given that it
would be in the same location in every file.
and, fwiw, isn't it possible to use a #pragma or some __attribute__ to
get rid of the warning?

There's a fairly easy way to select between few warnings and the inlined function:


Just look at the current src/util.h

I have made non-inlining the default, for producing fewer warnings. For release (or non-developer) versions, we may #define INLINE_STR_UNCONST in <config.h> or in, next to the -DNDEBUG.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]