Eponymous template member from a template mixin

Steven Schveighoffer schveiguy at gmail.com
Sat Aug 4 21:10:32 UTC 2018


On 8/4/18 4:10 PM, Yuxuan Shui wrote:
> This doesn't work:
> 
> template A() {
>      void B() {};
> }
> template B() {
>      mixin A!();
> }
> void main() {
>      B!()();
> }
> 
> Is this intentional?

I believe mixin templates introduce a new symbol namespace to a degree. 
I doubt you would be able to do something like this.

-Steve


More information about the Digitalmars-d-learn mailing list