June 07, 2006
D's access control maybe too simplified.
e.g if i need a member accessed by both subclass and package members, (package
protected foo?).


June 07, 2006
In article <e65t57$2osj$1@digitaldaemon.com>, icee says...
>
>D's access control maybe too simplified.
>e.g if i need a member accessed by both subclass and package members, (package
>protected foo?).

C# has a "protected internal" access which does exactly this, but in ~3 years of writing C# I've never felt the urge to use it.

If it's just an odd one-off case, I'd suggest using a 'protected' member and a 'package' getter property, or vice versa, rather than cluttering up the language.

cheers
Mike