June 07, 2006 a more fine access model? | ||||
---|---|---|---|---|
| ||||
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 Re: a more fine access model? | ||||
---|---|---|---|---|
| ||||
Posted in reply to icee | 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 |
Copyright © 1999-2021 by the D Language Foundation