Why is the following not working?

class Foo(string baz = "baz")
{
    mixin("int " ~ baz ~ ";");
}

class Bar : Foo
{
}

Shouldn't it implicit do, without me having to do it manually?

class Bar : Foo!"baz"
{
}

...

What's the reason you can't specify default values for template parameters on a class? Is it intended behavior or is it a bug?

https://run.dlang.io/is/tnOtn3

Reply via email to