From 47334c3d156fa35a382e7f5e0dbbb5a64308109b Mon Sep 17 00:00:00 2001 From: Alexey Kudravtsev Date: Tue, 5 Apr 2011 16:06:21 +0400 Subject: [PATCH] NPE --- .../codeInsight/daemon/impl/GeneralHighlightingPass.java | 1 + 1 file changed, 1 insertion(+) diff --git a/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/GeneralHighlightingPass.java b/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/GeneralHighlightingPass.java index b055d66e2a85..d0a9bacbfa29 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/GeneralHighlightingPass.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/daemon/impl/GeneralHighlightingPass.java @@ -338,6 +338,7 @@ public class GeneralHighlightingPass extends ProgressableTextEditorHighlightingP return JobUtil.invokeConcurrentlyUnderProgress(new ArrayList(injectedFiles), new Processor() { public boolean process(final PsiFile injectedPsi) { DocumentWindow documentWindow = (DocumentWindow)PsiDocumentManager.getInstance(myProject).getCachedDocument(injectedPsi); + if (documentWindow == null) return true; Place places = InjectedLanguageUtil.getShreds(injectedPsi); for (PsiLanguageInjectionHost.Shred place : places) { TextRange textRange = place.getRangeInsideHost().shiftRight(place.host.getTextRange().getStartOffset());