On Tue, 22 Jun 2004, MenTaLguY wrote:
On Tue, 2004-06-22 at 23:17, Bryce Harrington wrote:
Hmm... Yet another reason to consider using either the standard map<> template, or, if performance really is a serious issue, to implement a custom non-template version in the Inkscape codebase.
Or a custom template version. Nothing wrong with implementing a template container class that implements the appropriate STL interfaces.
True. IIRC, the STL developers had proposed some hash-based data structures including a hash map. Perhaps that is where hash_map came from. In any case, by now I'm sure some a good one could be found.
What does __attribute__ do? I haven't run across that before.
It lets you provide hints to the compiler like e.g. "this function never returns", "this function has no side-effects", "this function shouldn't be discarded even though it's apparently unused", and "this is deprecated" (my favorite).
Ahh, yes I guess I have run across that in your code. ;-)
Bryce