[Libreoffice] [PUSHED, partial] Re: [PATCH] new cppcheck cleaning in cppu and cppuhelper + error in compilation

Caolán McNamara caolanm at redhat.com
Wed Jan 12 05:56:00 PST 2011

On Wed, 2011-01-12 at 13:12 +0000, Caolán McNamara wrote:
> On Tue, 2011-01-11 at 23:17 +0100, Julien Nabet wrote:
> > It's better with the attachments :-)
> Hum, it all looks good except for the operator=, I mean, it compiles but
> I don't think it *should* compile :-) it is changing the state of
> "this". Something odd here.
> Pushed the rest of this however. Need to have another look at that
> operator=

Ah yeah, the const was *after* the SAL_THROW, it would need to go
*before* it to be const, i.e. 

inline Mapping & SAL_CALL operator = ( const Mapping & rMapping ) const


inline Mapping & SAL_CALL operator = ( const Mapping & rMapping )
SAL_THROW( () ) const

and that indeed doesn't compile. I think the cppcheck warning is bogus,
perhaps fixed in 2.47 and/or fixed with suitable -I flags to get it to
see the define of SAL_THROW.


More information about the LibreOffice mailing list