When I try add some sub type for struct with mixin template, seems there is no way to hidden the private type.

Is there a way to hidden type from mix template like Voldemort type ?

fake code:

mix template TypeX () {
    alias This = typeof(this);

    static struct Unique {
       This* _ptr ;
    }
    static struct Helper {
          private Unique data;
     }
     alias TypeX = {
         alias PublicName = Helper ;
     }
}

struct Node {
    mixin TypeX!();
    PublicName helper;
}



Reply via email to