interface A(T) { @property T Value(); @property T Value(T value); // need to enforce alias _value this somehow }
class B(T) : A!T { private T _value; @property T Value() { return _value; } @property T Value(T value) { return value = _value; } alias _value this; // B must use alias this so B(T) behaves like type T }