digitalmars.D - base class protection
- qniol (11/11) Jun 20 2009 Hello!
- Daniel Keep (3/19) Jun 20 2009 You'll have to be more specific about ref for us to be of assistance.
- Frank Benoit (3/20) Jun 20 2009 As far as I know, it *does* break compatibility with "Object".
- Jarrett Billingsley (6/15) Jun 20 2009 It's a remnant from presumably an earlier period in D's development.
Hello! What's "protection" here for? class Duper : protection Super { ... } for protection being either: private package public export and Super being a class. C++'s intuition let me down. D 1.0/2.0 ref. too (I got accustomed to it). thx for help!
Jun 20 2009
qniol wrote:Hello! What's "protection" here for? class Duper : protection Super { ... } for protection being either: private package public export and Super being a class.As far as I know, it doesn't *do* anything.C++'s intuition let me down. D 1.0/2.0 ref. too (I got accustomed to it). thx for help!You'll have to be more specific about ref for us to be of assistance.
Jun 20 2009
Daniel Keep schrieb:qniol wrote:As far as I know, it *does* break compatibility with "Object". http://d.puremagic.com/issues/show_bug.cgi?id=177Hello! What's "protection" here for? class Duper : protection Super { ... } for protection being either: private package public export and Super being a class.As far as I know, it doesn't *do* anything.
Jun 20 2009
On Sat, Jun 20, 2009 at 4:51 AM, qniol<qniol o2.pl> wrote:Hello! What's "protection" here for? class Duper : protection Super { ... } for protection being either: private package public export and Super being a class.It's a remnant from presumably an earlier period in D's development. Without MI, it's pointless. The default is public, and using anything other than public just breaks things. I'm surprised (well,.. not really) that it's been in the spec and compiler for so long without having been removed.
Jun 20 2009