Remove check in visibilities that allowed access to privates of outer packages

It doesn't work for a while now in imports and is planned to be dropped with upcoming changes to private
This commit is contained in:
Pavel V. Talanov
2015-05-13 17:15:57 +03:00
parent be66ee7015
commit 7585cbfe22
7 changed files with 51 additions and 17 deletions
@@ -53,11 +53,6 @@ public class Visibilities {
if (parent == fromParent) {
return true;
}
if (fromParent instanceof PackageFragmentDescriptor) {
return parent instanceof PackageFragmentDescriptor
&& ((PackageFragmentDescriptor) parent).getFqName().isAncestorOf(((PackageFragmentDescriptor) fromParent).getFqName())
&& DescriptorUtils.areInSameModule(fromParent, parent);
}
fromParent = fromParent.getContainingDeclaration();
}
return false;