diff lisp/progmodes/make-mode.el @ 65383:4dadc0d80d76

(makefile-add-log-defun): Trim the result.
author Richard M. Stallman <rms@gnu.org>
date Fri, 09 Sep 2005 01:24:59 +0000
parents 629afbe74e61
children 13abee3a9bc6 10fe5fadaf89
line wrap: on
line diff
--- a/lisp/progmodes/make-mode.el	Fri Sep 09 01:24:15 2005 +0000
+++ b/lisp/progmodes/make-mode.el	Fri Sep 09 01:24:59 2005 +0000
@@ -1833,6 +1833,10 @@
 		      ;; Don't keep looking across a blank line or comment.
 		      (looking-at "$\\|#")
 		      (not (zerop (forward-line -1))))))
+      ;; Remove leading and trailing whitespace.
+      (when found
+	(setq found (replace-regexp-in-string "[ \t]+\\'" "" found))
+	(setq found (replace-regexp-in-string "\\`[ \t]+" "" found)))
       found)))
 
 (provide 'make-mode)