Subject: bug#23648: [PATCH] `defun-declarations-alist' can be unintentionally modified

From: Dmitry Gutov <[email-masked]>
Date: Mon, 18 Jul 2016 22:17:56 +0300

On 07/18/2016 06:00 AM, [email-masked] wrote:

>> Here `delete-dups' destructively modifies a list that includes
>> `defun-declarations-alist' as its tail verbatim, not as a copy.
>> Attached patch should fix that.
>
> I agree with analysis and patch here.

I like the patch as well. Maybe it would be better to use 
cl-remove-duplicates with nconc instead (the use of nil is a little 
non-obvious), but that would require having cl-lib loaded at runtime, 
and elisp-mode depending on it.

In any case, the proposed patch looks safe.