KDE_ macros in kde_file.h
Jaison Lee
lee.jaison at gmail.com
Mon Oct 9 23:14:42 BST 2006
On 10/9/06, David Faure <faure at kde.org> wrote:
> On Monday 09 October 2006 20:35, Jaison Lee wrote:
> > Most of the KDE_* macros defined in kde_file.h (KDE_mkdir, KDE_open,
> > KDE_rename, KDE_stat, etc.) are not used at all, and those that are
> > are used sparingly (sometimes by only one class/function).
>
> They are very much used AFAICS... E.g. KDE_open is used in the following files:
6 files out of ~1500 (in kdelibs) is "very much used" to you? :) How
can you justify that? (And BTW: update your kdelibs; one of those
isn't using it anymore :P )
KDE_rename, KDE_sendfile, KDE_getpos, KDE_setpos, KDE_ftell,
KDE_fseek, and KDE_fstat are not used at all in the codebase.
KDE_readdir is used in 2 files. KDE_open and KDE_stat are the most
used, covering about 35 or so files, including extragear and
playground (proving that this "kdelibs internal" info is leaking out
to developers). I stand by my original assessment: they are sparingly
used. :)
> Granted, some/most of those could use QFile instead, but I don't see the point;
> don't fix it if it ain't broken as they say. KDE_foo is mostly for kdelibs itself, for
> low-level performance-critical code. Applications can use QFile or KIO indeed.
> We had a thread about this already iirc.
If this is indeed for kdelibs only than we should at least stop
installing it to kde/include, or even move to a KIO only header since
they are the only ones saying they need them. However, I'm wondering
just how much a noticeable speed improvement KDE_open is over QFile
when you are copying over ftp. :)
More information about the kde-core-devel
mailing list