On 01/27/2012 02:24 AM, Simen Kjærås wrote:
A pattern in D is this:

alias Foo!q{
stuffs
} MyFoo;

Where Foo is a templated struct/class. In many ways, this is similar to
defining a new type, and I therefore throw out the suggestion that the
syntax should reflect this. I may be wrong, but I think this syntax is
unused and fitting:

Foo MyFoo!q{
stuffs
}

This is clearly symmetrical with the definition of normal types:

class MyClass {
}

struct MyStruct {
}

enum MyEnum {
}

Critique? Thoughts?

It looks like Yoda speak to me. I don't think it is going to fly. If we get alias name = othername; as has been suggested a few times, your example would look like:

alias MyFoo = Foo!q{

}

Is that good enough?

Reply via email to