[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kdevelop-devel
Subject:    Re: KDE/kdevplatform/shell
From:       "Friedrich W. H. Kossebau" <kossebau () kde ! org>
Date:       2009-08-05 21:56:39
Message-ID: 200908052356.39731.kossebau () kde ! org
[Download RAW message or body]

Mercredi, le 5 août 2009, à 17:12, Andreas Pakulat a écrit:
> On 05.08.09 14:44:04, Friedrich W. H. Kossebau wrote:
> > Mercredi, le 5 août 2009, à 12:45, Andreas Pakulat a écrit:
> > > On 05.08.09 02:15:08, Friedrich W. H. Kossebau wrote:
> > > > SVN commit 1007055 by kossebau:
> > > >
> > > > changed: only need a QHash, not a QMap, for the KPart->QWidget
> > > > storage
> > >
> > > Whats the advantage of using QHash instead of QMap here?
> >
> > From http://doc.trolltech.com/4.5/qhash.html#details :
> > * QHash provides faster lookups than QMap
> >
> > And IIRC a QHash needs less memory than a QMap, but that is not
> > guaranteed.
>
> Next time, please do profiling first before you do micro-optimizations like
> this. I don't think the difference is noticeable in KDevelop.

Yes, seems I really should be more carefully instead of blindly applying Best 
practises in other people's code :/

Thanks Hugo for twisting my memories back, had it the other way round (and 
ignoring the operator<() needed hint for QMaps).

Cheers
Friedrich
-- 
Okteta - KDE 4 Hex Editor - http://utils.kde.org/projects/okteta

_______________________________________________
KDevelop-devel mailing list
KDevelop-devel@kdevelop.org
https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop-devel

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic