From: Stefan Monnier Date: Wed, 24 Nov 2004 15:20:38 +0000 (+0000) Subject: (generic-mode-set-comments): Accept an empty comment-end. X-Git-Tag: ttn-vms-21-2-B4~3705 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0e7acedf7b7777ffc845b504579cef1e5ca1c0fd;p=emacs.git (generic-mode-set-comments): Accept an empty comment-end. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ad0a8a1bb72..d2254e1c196 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,8 +1,12 @@ +2004-11-24 Stefan Monnier + + * generic.el (generic-mode-set-comments): Accept an empty comment-end. + 2004-11-24 Nick Roberts * progmodes/gdb-ui.el (dedicated-switch-to-buffer): New function. - (gdb-ann3, gdb-setup-windows, gdb-restore-windows): Dedicate - gdb-related windows. + (gdb-ann3, gdb-setup-windows, gdb-restore-windows): + Dedicate gdb-related windows. (gdb-display-buffer): Dedicate gdb-related windows. Don't grab other frames. (gdb-reset): Remove dedicated property after debugging. @@ -48,20 +52,19 @@ (math-comp-simplify, math-comp-simplify-term) (math-comp-add-string, math-comp-add-string-sel): Replace variables comp-highlight, comp-buf, comp-base, - comp-height, comp-tag, comp-hpos and comp-vpos by declared - variables. + comp-height, comp-tag, comp-hpos and comp-vpos by declared variables. 2004-11-23 Jan Dj,Ad(Brv - * cus-start.el (all): Added x-use-old-gtk-file-dialog. + * cus-start.el (all): Add x-use-old-gtk-file-dialog. * mail/emacsbug.el (report-emacs-bug): Catch error that x-server-vendor and x-server-version may throw. 2004-11-23 Kim F. Storm - * subr.el (substitute-key-definition-key): Optimize. Don't - call indirect-function for nil defn (always signals error). + * subr.el (substitute-key-definition-key): Optimize. + Don't call indirect-function for nil defn (always signals error). * ido.el (ido-read-internal): Fix require-match check when ido-directory-too-big is set. @@ -71,8 +74,7 @@ * calc/calc-ext.el (math-read-replacement-list) (math-read-superscripts): New variables. (math-read-preprocess-string): New function. - (math-read-expr): Filter input through - math-read-preprocess-string. + (math-read-expr): Filter input through math-read-preprocess-string. * calc/calc-aent.el (math-read-exprs): Filter input through math-read-preprocess-string. diff --git a/lisp/generic.el b/lisp/generic.el index 57937be6c0b..b246cd48d4a 100644 --- a/lisp/generic.el +++ b/lisp/generic.el @@ -289,13 +289,15 @@ Some generic modes are defined in `generic-x.el'." ;; Go through all the comments (dolist (start comment-list) - (let ((end ?\n) (comstyle "")) + (let ((end nil) (comstyle "")) ;; Normalize (when (consp start) (setq end (or (cdr start) end)) (setq start (car start))) (when (char-valid-p start) (setq start (char-to-string start))) - (when (char-valid-p end) (setq end (char-to-string end))) + (cond + ((char-valid-p end) (setq end (char-to-string end))) + ((zerop (length end)) (setq end "\n"))) ;; Setup the vars for `comment-region' (if comment-start @@ -414,5 +416,5 @@ The regexp is highlighted with FACE." (provide 'generic) -;;; arch-tag: 239c1fc4-1303-48d9-9ac0-657d655669ea +;; arch-tag: 239c1fc4-1303-48d9-9ac0-657d655669ea ;;; generic.el ends here