private boolean outOfMemoryExceptionCaught(PsiElement element) {
      PsiElement currentElement = element;
      while (true) {
        final PsiTryStatement containingTryStatement =
          PsiTreeUtil.getParentOfType(currentElement,
                                      PsiTryStatement.class);
        if (containingTryStatement == null) {
          return false;
        }
        if (catchesOutOfMemoryException(containingTryStatement)) {
          return true;
        }
        currentElement = containingTryStatement;
      }
    }
private boolean outOfMemoryExceptionCaught(PsiElement element)