don't drop PsiCacheKey cache on any change in a physical file

This commit is contained in:
peter
2016-03-09 15:35:52 +01:00
parent 3cdc8c9cf8
commit 32cc8e1093
@@ -76,7 +76,7 @@ public class PsiCacheKey<T, H extends PsiElement> extends Key<SoftReference<Pair
*/
private long getModificationCount(@NotNull PsiElement element) {
PsiFile file = element.getContainingFile();
long fileStamp = file == null ? 0 : file.getModificationStamp();
long fileStamp = file == null || file.isPhysical() ? 0 : file.getModificationStamp();
PsiModificationTracker tracker = file == null ? element.getManager().getModificationTracker()
: file.getManager().getModificationTracker();