Design of reflective enums
renoX
renosky at free.fr
Fri Feb 23 23:30:39 PST 2007
Michiel a écrit :
> renoX wrote:
>
>>> 2. Built-in enums do not produce symbols in object files. Neither
>>> should library implementation.
>> Well for reflective enums, you need to store the strings somewhere..
>
> Not if it's a core feature. Every request for a label could be replaced
> by a literal by the compiler.
I think that we do not understand, I'm talking about 'reflective enums'
not regular enums (after all the thread is 'design of reflective enums).
Reflective are enums where you can print also the *label* associated
with the enum, so there must be a function somewhere which have these
label strings to be able to print the label at runtime.
So the label strings must be of course stored in the binary for
reflective enums.
renoX
More information about the Digitalmars-d
mailing list