Subject: bug#36035: 26.2; doc string of `add-to-list'

From: Drew Adams <[email-masked]>
Date: Fri, 31 May 2019 13:46:16 -0700 (PDT)

The doc in (elisp) `List Variables' is OK.  The doc string is not.

The doc string says this:

  Add ELEMENT to the value of LIST-VAR if it isn't there yet.

That doesn't say what it does it ELEMENT _is_ already there (and it
should).

But one might easily get the impression that it does NOT add ELEMENT if
it is already present.  And that's just plain wrong.

(setq foo '((a . "aaa") (b . "bbb"))) ; => ((a . "aaa") (b . "bbb"))

(add-to-list 'foo '(a . "@@@@")) ; => ((a . "@@@@") (a . "aaa") (b . "bbb"))

In GNU Emacs 26.2 (build 1, x86_64-w64-mingw32)
 of 2019-04-13
Repository revision: fd1b34bfba8f3f6298df47c8e10b61530426f749
Windowing system distributor `Microsoft Corp.', version 10.0.17134
Configured using:
 `configure --without-dbus --host=x86_64-w64-mingw32
 --without-compress-install 'CFLAGS=-O2 -static -g3''