Re: [patch] constify g_simple_async_result_set_from_error



On Wed, 2009-09-02 at 14:53 -0400, Morten Welinder wrote:
> > With this change, it won't break (or add warnings) to any program. It
> > just removes a warning for programs that do not do the explicit cast,
> > and get given a const GError.
> 
> Really?
> 
> Take the program below and notice that the constified prototype
> introduces a warning.  If used from C++, that would be an error.

Last time I checked, GLib had a C api, not a C++ api...

We introduced const in oh so many places already (each
time with some protest from the C++ camp), let's
not discuss this to death yet again please.

I'd say just go ahead and make it const.

ciao,
--mitch




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