diff --git a/compiler/frontend/src/org/jetbrains/jet/lang/diagnostics/DiagnosticUtils.java b/compiler/frontend/src/org/jetbrains/jet/lang/diagnostics/DiagnosticUtils.java index be456c83593..82ca7a8ebe1 100644 --- a/compiler/frontend/src/org/jetbrains/jet/lang/diagnostics/DiagnosticUtils.java +++ b/compiler/frontend/src/org/jetbrains/jet/lang/diagnostics/DiagnosticUtils.java @@ -73,7 +73,7 @@ public class DiagnosticUtils { public static String atLocation(PsiFile file, TextRange textRange, Document document) { int offset = textRange.getStartOffset(); VirtualFile virtualFile = file.getVirtualFile(); - String pathSuffix = virtualFile == null ? "" : " in " + virtualFile.getPath(); + String pathSuffix = " in " + (virtualFile == null ? file.getName() : virtualFile.getPath()); return offsetToLineAndColumn(document, offset).toString() + pathSuffix; }