[Top][All Lists]

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

Re: vc-state and unregistered

From: Dmitry Gutov
Subject: Re: vc-state and unregistered
Date: Sun, 24 Apr 2016 15:21:52 +0300
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.0

On 04/24/2016 03:11 PM, Michael Albinus wrote:

That could be fixed with using `none' instead, like `vc-backend'
does. Which I've mentioned already.

That's the direction I have thought also. But in `vc-state' there is the
following comment:

The comment is about the API and which value to return, not how the value is cached. My sentence, quoted above, was about how to cache it.

  ;; Note: in Emacs 22 and older, return of nil meant the file was
  ;; unregistered.  This is potentially a source of
  ;; backward-compatibility bugs.

...and I have no idea how to interpret this comment. In Emacs 24, *and* in the upcoming 25.1, nil is *still* returned for unregistered files.

Since I don't know why nil has been replaced by `unregistered', it might
be a problem to use nil again as indication of unregistered files.

The salient question here is *in what way* has nil been replaced by `unregistered'.

we shouldn't change the interface wantonly, I believe.

The actual behavior will not change. This is what I'm proposing: to put the current behavior of (vc-state FILE) into spec.

reply via email to

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