From 43314bf6ef825063701459dae7575506b6f70c35 Mon Sep 17 00:00:00 2001 From: Lute Kamstra Date: Mon, 14 Mar 2005 11:07:07 +0000 Subject: [PATCH] (define-generic-mode): Let generic-mode-list be a list of strings; test membership with equal. --- lisp/ChangeLog | 5 +++++ lisp/generic.el | 5 ++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fc9baa42987..3b27d4c83b0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2005-03-14 Lute Kamstra + + * generic.el (define-generic-mode): Let generic-mode-list be a + list of strings; test membership with equal. + 2005-03-14 Kim F. Storm * simple.el (next-line, previous-line): Add optional try-vscroll diff --git a/lisp/generic.el b/lisp/generic.el index fe3c2c274af..9545b0970ac 100644 --- a/lisp/generic.el +++ b/lisp/generic.el @@ -1,6 +1,6 @@ ;;; generic.el --- defining simple major modes with comment and font-lock ;; -;; Copyright (C) 1997, 1999, 2004 Free Software Foundation, Inc. +;; Copyright (C) 1997, 1999, 2004, 2005 Free Software Foundation, Inc. ;; ;; Author: Peter Breton ;; Created: Fri Sep 27 1996 @@ -215,8 +215,7 @@ FUNCTION-LIST is a list of functions to call to do some additional setup. See the file generic-x.el for some examples of `define-generic-mode'." ;; Add a new entry - (unless (assq name generic-mode-list) - (push (list (symbol-name name)) generic-mode-list)) + (add-to-list 'generic-mode-list (symbol-name name)) ;; Add it to auto-mode-alist (dolist (re auto-mode-list) -- 2.39.2