avoid blocking runReadAction in debug logging

This commit is contained in:
Alexey Kudravtsev
2013-11-27 17:56:26 +04:00
parent 5b4f290c30
commit 96e001e5bc
@@ -492,7 +492,7 @@ public abstract class PassExecutorService implements Disposable {
public static void log(ProgressIndicator progressIndicator, TextEditorHighlightingPass pass, @NonNls Object... info) {
if (LOG.isDebugEnabled()) {
String docText = pass == null ? "" : StringUtil.first(pass.getDocument().getText(), 10, true);
CharSequence docText = pass == null ? "" : StringUtil.first(pass.getDocument().getCharsSequence(), 10, true);
synchronized (PassExecutorService.class) {
StringBuilder s = new StringBuilder();
for (Object o : info) {