GNU bug report logs - #23597
24.5; `cl-values-list' should not be an alias for `identity'

Previous Next

Package: emacs;

Reported by: Drew Adams <drew.adams <at> oracle.com>

Date: Sun, 22 May 2016 00:27:01 UTC

Severity: wishlist

Tags: fixed

Found in version 24.5

Fixed in version 27.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 23597 <at> debbugs.gnu.org
Subject: bug#23597: 24.5; `cl-values-list' should not be an alias for `identity'
Date: Sun, 28 Jul 2019 14:15:31 +0200
Drew Adams <drew.adams <at> oracle.com> writes:

> Emacs Lisp does not support multiple values for its Common Lisp
> emulation.  OK, fine.
>
> But that is not a reason for this kind of definition.
>
> `cl-values-list' should at least raise an error if its arg is not a
> list.  That too is part of the Common Lisp definition of `values-list':
> "Should signal type-error if its argument is not a proper list."
>
> (cl-values-list 5) should not return 5.  It should raise a wrong-type
> arg error.

I agree.

I've gone through the Emacs trunk to see whether tightening up the
definition would lead to any problems, but all the usages are on the
form

  (cl-multiple-value-bind (tree header tree-buffer)
      (cl-values-list (ebrowse-choose-tree))

which would already bug out if what's returned is not a list.

So I've now made this change on the trunk.  In the unlikely case that
this leads to problems with out-of-tree code, we should be open to
reverting it.

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




This bug report was last modified 5 years and 297 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.