Function: meta-beginning-of-defun

meta-beginning-of-defun is an interactive and byte-compiled function defined in meta-mode.el.gz.

Signature

(meta-beginning-of-defun &optional ARG)

Documentation

Move backward to beginning of a defun in Metafont or MetaPost code.

With numeric argument, do it that many times. Negative arg -N means move forward to Nth following beginning of defun. Returns t unless search stops due to beginning or end of buffer.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/meta-mode.el.gz
(defun meta-beginning-of-defun (&optional arg)
  "Move backward to beginning of a defun in Metafont or MetaPost code.
With numeric argument, do it that many times.
Negative arg -N means move forward to Nth following beginning of defun.
Returns t unless search stops due to beginning or end of buffer."
  (interactive "p")
  (if (or (null arg) (= 0 arg)) (setq arg 1))
  (and arg (< arg 0) (not (eobp)) (forward-char 1))
  (and (re-search-backward
        (concat "\\<" meta-begin-defun-regexp "\\>") nil t arg)
       (progn (goto-char (match-beginning 0))
              (skip-chars-backward "%")
              (skip-chars-backward " \t\f") t)))