EA-55785 - assert: ComponentManagerImpl.getComponent

This commit is contained in:
Alexey Kudravtsev
2014-12-24 12:11:58 +03:00
parent 8ce50eec9c
commit 3a3a34e326
@@ -224,6 +224,7 @@ public class SelfElementInfo implements SmartPointerElementInfo {
return ApplicationManager.getApplication().runReadAction(new NullableComputable<PsiFile>() {
@Override
public PsiFile compute() {
if (project.isDisposed()) return null;
VirtualFile child;
if (virtualFile.isValid()) {
child = virtualFile;
@@ -285,7 +286,7 @@ public class SelfElementInfo implements SmartPointerElementInfo {
}
@Override
public boolean pointsToTheSameElementAs(@NotNull SmartPointerElementInfo other) {
public boolean pointsToTheSameElementAs(@NotNull final SmartPointerElementInfo other) {
if (other instanceof SelfElementInfo) {
SelfElementInfo otherInfo = (SelfElementInfo)other;
return Comparing.equal(myVirtualFile, otherInfo.myVirtualFile)
@@ -296,7 +297,12 @@ public class SelfElementInfo implements SmartPointerElementInfo {
&& mySyncEndOffset == otherInfo.mySyncEndOffset
;
}
return Comparing.equal(restoreElement(), other.restoreElement());
return ApplicationManager.getApplication().runReadAction(new Computable<Boolean>() {
@Override
public Boolean compute() {
return Comparing.equal(restoreElement(), other.restoreElement());
}
});
}
@Override