boolean (@NotNull PsiElement element) { final VirtualFile file = element.getContainingFile().getVirtualFile(); return file != null && !ReadonlyStatusHandler.getInstance(element.getProject()).ensureFilesWritable(Collections.singletonList(file)).hasReadonlyFiles(); }