Subject: bug#51096: [PATCH] Remove XEmacs compat code from sql.el

From: Stefan Kangas <[email-masked]>
Date: Fri, 8 Oct 2021 15:09:45 -0400

Severity: wishlist

The attached patch removes the XEmacs compatibility code from sql.el.

The Emacs FAQ currently has this to say:

    4.11 What was XEmacs?
    =====================

    XEmacs was a branch version of Emacs that is no longer actively
    developed.  Originally known as “Lucid Emacs”, XEmacs was forked from a
    prerelease version of Emacs 19.  XEmacs last released a new version on
    January 30, 2009, which lacks many important features that exist in
    Emacs.  Since its development has stopped, we do not expect to see any
    new releases.

       In the past, it was not uncommon for Emacs packages to include code
    for compatibility with XEmacs.  Nowadays, most built-in and third party
    packages have either stopped supporting XEmacs or were developed
    exclusively for Emacs.

IOW, this support is probably not relevant to maintain these days.

Any objections to the attached patch?
From eee5301d7338aa28f0227c29687f0707c26f9a5a Mon Sep 17 00:00:00 2001
From: Stefan Kangas <[email-masked]>
Date: Fri, 8 Oct 2021 21:04:04 +0200
Subject: [PATCH] Remove XEmacs compat code from sql.el

* lisp/progmodes/sql.el (sql-interactive-mode-map, sql-mode)
(sql-interactive-mode): Remove XEmacs compat code.
---
 lisp/progmodes/sql.el | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el
index d0e0a1154e..f55115e902 100644
--- a/lisp/progmodes/sql.el
+++ b/lisp/progmodes/sql.el
@@ -1352,8 +1352,6 @@ sql-is-sqli-buffer-p
 (defvar sql-interactive-mode-map
   (let ((map (make-sparse-keymap)))
     (set-keymap-parent map comint-mode-map)
-    (if (fboundp 'set-keymap-name)
-	(set-keymap-name map 'sql-interactive-mode-map)); XEmacs
     (define-key map (kbd "C-j") 'sql-accumulate-and-indent)
     (define-key map (kbd "C-c C-w") 'sql-copy-column)
     (define-key map (kbd "O") 'sql-magic-go)
@@ -4160,10 +4158,6 @@ sql-mode
 	    (modify-syntax-entry ?\\\\ \"\\\\\" sql-mode-syntax-table)))"
   :abbrev-table sql-mode-abbrev-table
 
-  (when (and (featurep 'xemacs)
-             sql-mode-menu)
-      (easy-menu-add sql-mode-menu))
-
   ;; (smie-setup sql-smie-grammar #'sql-smie-rules)
   (setq-local comment-start "--")
   ;; Make each buffer in sql-mode remember the "current" SQLi buffer.
@@ -4286,9 +4280,6 @@ sql-interactive-mode
   (setq mode-name
         (concat "SQLi[" (or (sql-get-product-feature sql-product :name)
                             (symbol-name sql-product)) "]"))
-  (when (and (featurep 'xemacs)
-             sql-interactive-mode-menu)
-    (easy-menu-add sql-interactive-mode-menu))
 
   ;; Note that making KEYWORDS-ONLY nil will cause havoc if you try
   ;; SELECT 'x' FROM DUAL with SQL*Plus, because the title of the column
-- 
2.30.2