[AC] Unbreak `beginning-of-defun'

Andreas Roehler andreas.roehler at online.de
Thu Oct 1 04:35:49 EDT 2009


Michael Sperber wrote:
> Yo Andreas,
> 
> it would have been nice if you'd looked at my review comments ...


Don't see any, didn't get any.
May you point me to, should I miss it?

Stephen, IIRC exists still a list of that kind.
May you put me on it?

Thanks

Andreas



> 
> 2009-09-30  Mike Sperber  <mike at xemacs.org>
> 
> 	* lisp.el (beginning-of-defun-raw): Unbreak; clean up sloppy
> 	coding.
> 
> 
> ------------------------------------------------------------------------
> 
> diff --git a/lisp/lisp.el b/lisp/lisp.el
> --- a/lisp/lisp.el
> +++ b/lisp/lisp.el
> @@ -190,17 +190,17 @@
>  This is identical to beginning-of-defun, except that point does not move
>  to the beginning of the line when `defun-prompt-regexp' is non-nil."
>    (interactive "p")
> -   ;; (and arg (< arg 0) (not (eobp)) (forward-char 1))
>    (unless arg (setq arg 1))
> -  (cond
> -   (beginning-of-defun-function
> -    (funcall beginning-of-defun-function arg))
> -   (t (re-search-backward (if defun-prompt-regexp
> -                              (concat "^\\s(\\|"
> -                                      "\\(" defun-prompt-regexp "\\)\\s(")
> -                            "^\\s(")
> -			    nil 'move (or arg 1))
> -	(progn (goto-char (1- (match-end 0)))) t)))
> +  (if beginning-of-defun-function
> +      (funcall beginning-of-defun-function arg)
> +    (and (< arg 0) (not (eobp)) (forward-char 1))
> +    (and
> +     (re-search-backward (if defun-prompt-regexp
> +			     (concat "^\\s(\\|"
> +				     "\\(" defun-prompt-regexp "\\)\\s(")
> +			   "^\\s(")
> +			 nil 'move arg)
> +     (progn (goto-char (1- (match-end 0)))) t)))
>  
>  ;; XEmacs change (optional buffer parameter)
>  (defun buffer-end (arg &optional buffer)
> 




More information about the XEmacs-Patches mailing list