User Defined Attributes

Tove tove at fransson.se
Fri Nov 16 05:12:33 PST 2012


On Friday, 16 November 2012 at 10:41:44 UTC, Walter Bright wrote:
> The whole point of my example was no, you do not necessarily 
> know the meaning of a user-defined type that is used as an 
> attribute.

Agree. Imagine we have 3 generic libs/modules...
"Optimized CTFE Polygon Primitive Lib", Math, Gfx
... and then the "end user", creates a program.

Both Math and Gfx, want to use the optimized Polygon in their 
modules...

[Polygon(...)]
struct SpaceShip
{
}

This is just as ambiguous as if you had used a built-in int:s... 
and it can be solved in the exact same way which I outlined in 
the other thread.



More information about the Digitalmars-d-announce mailing list