29 May
2006
29 May
'06
8:06 p.m.
On Monday 29 May 2006 13:42, Jens Müller wrote:
I used something like I quoted from the docs (struct with only a type), and then used a default-constructed value (my_property_t()) to access the map.
Is that "worse style" than the one currently employed in the lib?
I guess that's a matter of opinion. Personally, I don't see it as worse style.
Is constructing/passing a struct with no data members more efficient than it is with an enum, or is there no difference?
I don't know, but I would bet that the difference--it it exists at all--is negligible. Ideally the compiler will elide the struct/enum object altogether, since it's only the type that's important. D.