Mercurial > emacs
changeset 77493:dd5c0a36a2d6
(idlwave-beginning-of-subprogram, idlwave-end-of-subprogram): Take
optional NOMARK arg to prevent pushing mark.
(idlwave-current-routine): Don't push mark.
author | J.D. Smith <jdsmith@as.arizona.edu> |
---|---|
date | Wed, 25 Apr 2007 20:44:25 +0000 |
parents | bcf5ca699533 |
children | a23be073aa2f |
files | lisp/progmodes/idlwave.el |
diffstat | 1 files changed, 10 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/idlwave.el Wed Apr 25 05:53:17 2007 +0000 +++ b/lisp/progmodes/idlwave.el Wed Apr 25 20:44:25 2007 +0000 @@ -2411,16 +2411,18 @@ ;; Reindent new line (idlwave-indent-line))) -(defun idlwave-beginning-of-subprogram () - "Moves point to the beginning of the current program unit." +(defun idlwave-beginning-of-subprogram (&optional nomark) + "Moves point to the beginning of the current program unit. +If NOMARK is non-nil, do not push mark." (interactive) - (idlwave-find-key idlwave-begin-unit-reg -1)) - -(defun idlwave-end-of-subprogram () - "Moves point to the start of the next program unit." + (idlwave-find-key idlwave-begin-unit-reg -1 nomark)) + +(defun idlwave-end-of-subprogram (&optional nomark) + "Moves point to the start of the next program unit. +If NOMARK is non-nil, do not push mark." (interactive) (idlwave-end-of-statement) - (idlwave-find-key idlwave-end-unit-reg 1)) + (idlwave-find-key idlwave-end-unit-reg 1 nomark)) (defun idlwave-mark-statement () "Mark current IDL statement." @@ -2535,7 +2537,7 @@ "Return (NAME TYPE CLASS) of current routine." (idlwave-routines) (save-excursion - (idlwave-beginning-of-subprogram) + (idlwave-beginning-of-subprogram 'nomark) (if (looking-at "[ \t]*\\<\\(pro\\|function\\)\\>\\s-+\\(\\([a-zA-Z0-9$_]+\\)::\\)?\\([a-zA-Z0-9$_]+\\)") (let* ((type (if (string= (downcase (match-string 1)) "pro") 'pro 'function))