diff --git a/platform/lang-impl/src/com/intellij/codeInsight/completion/CompletionProgressIndicator.java b/platform/lang-impl/src/com/intellij/codeInsight/completion/CompletionProgressIndicator.java index 3668b2d3c029..9b3739e755e9 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/completion/CompletionProgressIndicator.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/completion/CompletionProgressIndicator.java @@ -594,7 +594,7 @@ public class CompletionProgressIndicator extends ProgressIndicatorBase implement for (Pair> pair : myRestartingPrefixConditions) { int start = pair.first; if (caretOffset < start) { - LOG.error("caret=" + caretOffset + "; start=" + start); + LOG.error("caret=" + caretOffset + "; start=" + start + "; phase=" + CompletionServiceImpl.getPhaseRaw() + "; running=" + isRunning() + "; canceled=" + isCanceled()); } final String newPrefix = text.subSequence(start, caretOffset).toString(); if (pair.second.accepts(newPrefix)) { diff --git a/platform/lang-impl/src/com/intellij/codeInsight/completion/impl/CompletionServiceImpl.java b/platform/lang-impl/src/com/intellij/codeInsight/completion/impl/CompletionServiceImpl.java index 7afb1e52da5e..5db728098265 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/completion/impl/CompletionServiceImpl.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/completion/impl/CompletionServiceImpl.java @@ -225,7 +225,7 @@ public class CompletionServiceImpl extends CompletionService{ public static CompletionPhase getCompletionPhase() { // ApplicationManager.getApplication().assertIsDispatchThread(); - CompletionPhase phase = ourPhase; + CompletionPhase phase = getPhaseRaw(); ProgressIndicator indicator = ProgressManager.getInstance().getProgressIndicator(); if (indicator != null) { indicator.checkCanceled(); @@ -233,6 +233,10 @@ public class CompletionServiceImpl extends CompletionService{ return phase; } + public static CompletionPhase getPhaseRaw() { + return ourPhase; + } + public CompletionSorterImpl defaultSorter(CompletionParameters parameters, final PrefixMatcher matcher) { final CompletionLocation location = new CompletionLocation(parameters);