On Saturday, 30 November 2013 at 18:16:23 UTC, Walter Bright wrote:
It's easier than that:

struct Rectangular {
    Point x,y;
}

struct Rectangular {
    Rectangle rectangle;
    alias this rectangle;
}

The other day in IRC I asked about the transition to the newer alias X = Type syntax (I would love to see it everywhere!), and someone was saying that the "alias this" syntax always tripped him, because the name misleadingly suggests that the 'this' comes after the 'alias'. I guess it trips everybody :-)

Reply via email to