www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Module access to private members of synchronized classes

reply =?UTF-8?Q?Nemanja_Bori=C4=87?= <4burgos gmail.com> writes:
In the TDPL, on page 419:


"Not so for synchronized classes, which obey the following rules:
- Access to private members is restricted to methods of the class."


I can't find anything in the specs on this, so is this valid statement?

I've found a issue by Andrej here where he mentioned this (
http://forum.dlang.org/thread/bug-7903-3 https.d.puremagic.com%2Fissues%2F),
but no confirmation on these questions.

DMD is allowing this, and the fork which doesn't is here, but I'm not sure
if I should file a bug, as this is not in the specs:
https://github.com/NemanjaBoric/dmd (first push ever, don't mind me if
something is wrong there)


Thanks,
Nemanja
Apr 07 2014
parent =?UTF-8?Q?Nemanja_Bori=C4=87?= <4burgos gmail.com> writes:
Yes, I saw that, but as far as I can see it, that pull request is only
fixing issue with public members in synchronized classes, and I'm talking
about
not allowing access to the private members in the classes contained in the
same module. However, I'm not able to find anything on that in
the D specs, only in TDPL.

Sorry if I'm getting something wrong here!
Apr 08 2014