[Kde-pim] [patch] make gpgme++ portable to msvc

Marc Mutz marc at kdab.net
Tue Dec 11 12:54:20 GMT 2007


On Tuesday December 11 2007 13:47, Jaroslaw Staniek wrote:
> Marc Mutz said the following, On 2007-12-08 11:20:
> > <snip>
> >
> >> Index: result_p.h
> >> ===================================================================
> >> --- result_p.h  (revision 746016)
> >> +++ result_p.h  (working copy)
> >> @@ -33,7 +33,7 @@
> >>
> >>  #define make_error_ctor(x) \
> >>  GpgME::x::x( const Error & error ) \
> >> -  : GpgME::Result( error ), d( 0 ) \
> >> +  : GpgME::Result( error.toErrorCode() ), d( 0 ) \
> >
> > GpgME::Result should probably take an GpgME::Error as ctor arg right
> > away, here, don't you think? :)
>
> So remove Error(int)

yes

> and add 
> explicit Result( const Error& error = Error() ) : mError( error ) {} ?

yes, or rather add Result(Error)

> And add changes like this averywhere?:
>
> GpgME::VerificationResult::VerificationResult( gpgme_ctx_t ctx, int error )
>
>    : GpgME::Result( Error(error) ), d( 0 )
>
>                     ^^^^^^

You don't have to. I was just remarking on the needless Error -> unsigned 
int -> Error conversion in the quoted hunk of the diff.

Thanks,
Marc

-- 
Marc Mutz - marc at kdab.com, mutz at kde.org - Klarälvdalens Datakonsult AB
Platform-independent software solutions - www.kdab.com info at kdab.com
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list