emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/add-log.el


From: Miles Bader
Subject: [Emacs-diffs] Changes to emacs/lisp/add-log.el
Date: Fri, 04 Apr 2003 01:21:40 -0500

Index: emacs/lisp/add-log.el
diff -c emacs/lisp/add-log.el:1.142 emacs/lisp/add-log.el:1.143
*** emacs/lisp/add-log.el:1.142 Mon Dec  2 11:09:02 2002
--- emacs/lisp/add-log.el       Sat Jan 18 16:20:10 2003
***************
*** 545,580 ****
      ;; Now insert the function name, if we have one.
      ;; Point is at the item for this file,
      ;; either at the end of the line or at the first blank line.
!     (if defun
!       (progn
!         ;; Make it easy to get rid of the function name.
!         (undo-boundary)
!         (unless (save-excursion
!                   (beginning-of-line 1)
!                   (looking-at "\\s *$"))
!           (insert ?\ ))
!         ;; See if the prev function name has a message yet or not.
!         ;; If not, merge the two items.
!         (let ((pos (point-marker)))
!           (if (and (skip-syntax-backward " ")
!                    (skip-chars-backward "):")
!                    (looking-at "):")
!                    (progn (delete-region (+ 1 (point)) (+ 2 (point))) t)
!                    (> fill-column (+ (current-column) (length defun) 3)))
!               (progn (delete-region (point) pos)
!                      (insert ", "))
!             (goto-char pos)
!             (insert "("))
!           (set-marker pos nil))
!         (insert defun "): ")
!         (if version
!             (insert version ?\ )))
!       ;; No function name, so put in a colon unless we have just a star.
        (unless (save-excursion
                (beginning-of-line 1)
!               (looking-at "\\s *\\(\\*\\s *\\)?$"))
!       (insert ": ")
!       (if version (insert version ?\ ))))))
  
  ;;;###autoload
  (defun add-change-log-entry-other-window (&optional whoami file-name)
--- 545,578 ----
      ;; Now insert the function name, if we have one.
      ;; Point is at the item for this file,
      ;; either at the end of the line or at the first blank line.
!     (if (not defun)
!       ;; No function name, so put in a colon unless we have just a star.
!       (unless (save-excursion
!                 (beginning-of-line 1)
!                 (looking-at "\\s *\\(\\*\\s *\\)?$"))
!         (insert ": ")
!         (if version (insert version ?\ )))
!       ;; Make it easy to get rid of the function name.
!       (undo-boundary)
        (unless (save-excursion
                (beginning-of-line 1)
!               (looking-at "\\s *$"))
!       (insert ?\ ))
!       ;; See if the prev function name has a message yet or not.
!       ;; If not, merge the two items.
!       (let ((pos (point-marker)))
!       (skip-syntax-backward " ")
!       (skip-chars-backward "):")
!       (if (and (looking-at "):")
!                (> fill-column (+ (current-column) (length defun) 4)))
!           (progn (delete-region (point) pos) (insert ", "))
!         (if (looking-at "):")
!             (delete-region (+ 1 (point)) (line-end-position)))
!         (goto-char pos)
!         (insert "("))
!       (set-marker pos nil))
!       (insert defun "): ")
!       (if version (insert version ?\ )))))
  
  ;;;###autoload
  (defun add-change-log-entry-other-window (&optional whoami file-name)
***************
*** 829,835 ****
                 (if (re-search-backward "address@hidden \t]+\\([^,\n]+\\)" nil 
t)
                     (match-string-no-properties 1)))
                ((memq major-mode '(perl-mode cperl-mode))
!                (if (re-search-backward "^sub[ \t]+\\([^ \t\n]+\\)" nil t)
                     (match-string-no-properties 1)))
                ;; Emacs's autoconf-mode installs its own
                ;; `add-log-current-defun-function'.  This applies to
--- 827,833 ----
                 (if (re-search-backward "address@hidden \t]+\\([^,\n]+\\)" nil 
t)
                     (match-string-no-properties 1)))
                ((memq major-mode '(perl-mode cperl-mode))
!                (if (re-search-backward "^sub[ \t]+\\([^({ \t\n]+\\)" nil t)
                     (match-string-no-properties 1)))
                ;; Emacs's autoconf-mode installs its own
                ;; `add-log-current-defun-function'.  This applies to




reply via email to

[Prev in Thread] Current Thread [Next in Thread]