Introduce MutableDiagnosticsWithSuppression and use it in BindingTrace implementations

Exposes the fact that Diagnostics is in fact a mutable entity with readonly API
Update readonly view when diagnostics are modified
Allows to avoid recreating DiagnosticsWithSuppression every time getDiagnostics() is called in DelegatingBindingTrace
  which led to severe performance issues for large files with lots of diagnostics
This commit is contained in:
Pavel V. Talanov
2014-10-09 15:13:37 +04:00
parent d7c06f0527
commit 19ec9f9eda
6 changed files with 84 additions and 19 deletions
@@ -124,7 +124,7 @@ public class JetTestUtils {
@NotNull
@Override
public Diagnostics getDiagnostics() {
throw new UnsupportedOperationException(); // TODO
return Diagnostics.EMPTY;
}
@Override