[LC++]enum, #define, const, static const, or member const???
Vincent.Penquerch at artworks.co.uk
Tue Apr 2 21:49:05 UTC 2002
> I want to define a certain class type. Objects of this
> type will have an attribute called "kind", indicating what
> kind of object it is. There will be a finite collection of
> different kinds of object.
Have you thought of RTTI (that's standard C++).
It's a bit slower, though, as it works off a chain of inheritance
rather than vtable calls.
Basically, it adds a new entry in the vtable that points to a
structure describing the type of an object.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the tuxCPProgramming