void (@NotNull Editor editor) { if (editor instanceof EditorImpl) { ((EditorImpl)editor).throwDisposalError("Editor " + editor + " hasn't been released:"); } throw new RuntimeException("Editor of " + editor.getClass() + " and the following text hasn't been released:\n" + editor.getDocument().getText()); }