X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/52b410c60aebeb769ec9580af25ca50df2a44751..81deba3d7a2b187d58fe26bd8b4eafb5687095e1:/lisp/vc/ediff-init.el diff --git a/lisp/vc/ediff-init.el b/lisp/vc/ediff-init.el index 589ea45496..d6b538cff2 100644 --- a/lisp/vc/ediff-init.el +++ b/lisp/vc/ediff-init.el @@ -1,6 +1,6 @@ ;;; ediff-init.el --- Macros, variables, and defsubsts used by Ediff -;; Copyright (C) 1994-2014 Free Software Foundation, Inc. +;; Copyright (C) 1994-2015 Free Software Foundation, Inc. ;; Author: Michael Kifer ;; Package: ediff @@ -24,6 +24,8 @@ ;;; Code: +(require 'cl-lib) + ;; Start compiler pacifier (defvar ediff-metajob-name) (defvar ediff-meta-buffer) @@ -118,11 +120,8 @@ It needs to be killed when we quit the session.") (?C . ediff-buffer-C))) ;;; Macros -(defmacro ediff-odd-p (arg) - `(eq (logand ,arg 1) 1)) - -(defmacro ediff-buffer-live-p (buf) - `(and ,buf (get-buffer ,buf) (buffer-name (get-buffer ,buf)))) +(defsubst ediff-buffer-live-p (buf) + (and buf (get-buffer buf) (buffer-name (get-buffer buf)))) (defmacro ediff-get-buffer (arg) `(cond ((eq ,arg 'A) ediff-buffer-A) @@ -1456,7 +1455,7 @@ This default should work without changes." ;; The value of dif-num is always 1- the one that user sees. ;; This is why even face is used when dif-num is odd. (ediff-get-symbol-from-alist - buf-type (if (ediff-odd-p dif-num) + buf-type (if (cl-oddp dif-num) ediff-even-diff-face-alist ediff-odd-diff-face-alist) ))