Why isn't the 'operator==' in ksslcertificate not a boolean?

Richard Dale richard_dale at tipitina.demon.co.uk
Tue Jul 10 13:59:17 BST 2007


On Tuesday 10 July 2007, Thiago Macieira wrote:
> Richard Dale wrote:
> >In ksslcertificate.h there are these two methods:
> >
> >KIO_EXPORT int operator==(KSSLCertificate& x, KSSLCertificate& y);
> >KIO_EXPORT inline int operator!=(KSSLCertificate& x, KSSLCertificate& y)
> >{ return !(x == y); }
> >
> >Is there any reason why they don't return a bool value?
>
> Because it's KDE 2 code no one has cleaned up yet.
>
> That's a private API. Do not create a binding for it, please.
OK, thanks I'll remove it. But there is no way to tell from reading the header 
that it's private. I would rather private classes had 'Private' in their 
names, or the header ended with '_p.h' like the private Qt ones do.

-- Richard






More information about the kde-core-devel mailing list