Function: prog-fill-reindent-defun-default

prog-fill-reindent-defun-default is an interactive and byte-compiled function defined in prog-mode.el.gz.

Signature

(prog-fill-reindent-defun-default &optional JUSTIFY)

Documentation

Default implementation of prog-fill-reindent-defun.

JUSTIFY is the same as in fill-paragraph.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/progmodes/prog-mode.el.gz
(defun prog-fill-reindent-defun-default (&optional justify)
  "Default implementation of `prog-fill-reindent-defun'.
JUSTIFY is the same as in `fill-paragraph'."
  (interactive "P")
  (save-excursion
    (if (prog--text-at-point-p)
        (fill-paragraph justify (region-active-p))
      (beginning-of-defun)
      (let ((start (point)))
        (end-of-defun)
        (indent-region start (point) nil)))))