bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#45016: 26.3; when in ediff-current-file, 'D' (view diff) shows empty


From: Lars Ingebrigtsen
Subject: bug#45016: 26.3; when in ediff-current-file, 'D' (view diff) shows empty diff
Date: Sun, 24 Jan 2021 00:27:19 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Guilhem Bichot <guilhem.bichot@wanadoo.fr> writes:

> * start emacs -Q
> * create a file named, for example, /tmp/a
> * put a line of text in it, save it
> * add some characters to this line, don't save
> * launch M-x ediff-current-file
> * press D to view the diff
> * a buffer opens to show the diff but it is empty. I expected to see a
> non-empty diff (a context diff, as ediff-custom-diff-options is at its
> default "-c").
> * if instead of D I press C-u D then I do get a non-empty plain diff
> (non-context, non-unified).

This bug is still present in Emacs 28.

This is how the `D' command starts:

(defun ediff-show-diff-output (arg)
  (interactive "P")
[...]
  (let ((buf (cond ((and arg (ediff-buffer-live-p ediff-diff-buffer))
                    ediff-diff-buffer)
                   ((ediff-buffer-live-p ediff-custom-diff-buffer)
                    ediff-custom-diff-buffer)

There's helpfully no doc string here (or comments) about what `arg' is
meant to express, but if we have `arg', we work on `ediff-diff-buffer'
(and this works), and if we don't have `arg', then
`ediff-custom-diff-buffer' is used (and this doesn't work).

I'm pretty unfamiliar with ediff -- does anybody know what the intention
here is for the prefix arg?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]