Variable: diff-mode-abbrev-table

diff-mode-abbrev-table is a variable defined in diff-mode.el.gz.

Value

[## 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0]

Documentation

Abbrev table for diff-mode.

Source Code

;; Defined in /usr/src/emacs/lisp/vc/diff-mode.el.gz
;;;###autoload
(define-derived-mode diff-mode fundamental-mode "Diff"
  "Major mode for viewing/editing context diffs.
Supports unified and context diffs as well as (to a lesser extent)
normal diffs.

When the buffer is read-only, the ESC prefix is not necessary.
If you edit the buffer manually, `diff-mode' will try to update the hunk
headers for you on-the-fly.

You can also switch between context diff and unified diff with \\[diff-context->unified],
or vice versa with \\[diff-unified->context] and you can also reverse the direction of
a diff with \\[diff-reverse-direction].

\\{diff-mode-map}"

  (setq-local font-lock-defaults diff-font-lock-defaults)
  (add-hook 'font-lock-mode-hook #'diff--font-lock-cleanup nil 'local)
  (setq-local outline-regexp diff-outline-regexp)
  (setq-local imenu-generic-expression
              diff-imenu-generic-expression)
  ;; These are not perfect.  They would be better done separately for
  ;; context diffs and unidiffs.
  ;; (setq-local paragraph-start
  ;;        (concat "@@ "			; unidiff hunk
  ;;           "\\|\\*\\*\\* "		; context diff hunk or file start
  ;;           "\\|--- [^\t]+\t"))	; context or unidiff file
  ;;                                    ; start (first or second line)
  ;;   (setq-local paragraph-separate paragraph-start)
  ;;   (setq-local page-delimiter "--- [^\t]+\t")
  ;; compile support
  (setq-local next-error-function #'diff-next-error)

  (setq-local beginning-of-defun-function #'diff-beginning-of-file-and-junk)
  (setq-local end-of-defun-function #'diff-end-of-file)

  (diff-setup-whitespace)

  (if diff-default-read-only
      (setq buffer-read-only t))
  ;; setup change hooks
  (if (not diff-update-on-the-fly)
      (add-hook 'write-contents-functions #'diff-write-contents-hooks nil t)
    (make-local-variable 'diff-unhandled-changes)
    (add-hook 'after-change-functions #'diff-after-change-function nil t)
    (add-hook 'post-command-hook #'diff-post-command-hook nil t))
  ;; Neat trick from Dave Love to add more bindings in read-only mode:
  (let ((ro-bind (cons 'buffer-read-only diff-mode-shared-map)))
    (add-to-list 'minor-mode-overriding-map-alist ro-bind)
    ;; Turn off this little trick in case the buffer is put in view-mode.
    (add-hook 'view-mode-hook
	      (lambda ()
		(setq minor-mode-overriding-map-alist
		      (delq ro-bind minor-mode-overriding-map-alist)))
	      nil t))
  ;; add-log support
  (setq-local add-log-current-defun-function #'diff-current-defun)
  (setq-local add-log-buffer-file-name-function
              (lambda () (diff-find-file-name nil 'noprompt)))
  (add-function :filter-return (local 'filter-buffer-substring-function)
                #'diff--filter-substring)
  (unless buffer-file-name
    (hack-dir-local-variables-non-file-buffer))
  (save-excursion
    (setq-local diff-buffer-type
                (if (re-search-forward "^diff --git" nil t)
                    'git
                  nil))))