[Bug-openmcl] values-list
bryan o'connor
bryan-openmcl at lunch.org
Thu Jan 8 16:51:41 MST 2004
values-list should signal type-error if its argument
is not a proper list.
it's a trivial patch to signal the right error if
the arg is not a list. raising the signal on an
improper list seems more difficult.
since values-list is using apply to do its work,
that would mean coding apply signal a type-error
instead of "Can't construct argument list from ~S"
i think the latter is a more useful error message.
the right solution might be to rewrite values-list
to be recursive and not use apply. any thoughts?
...bryan
-------------- next part --------------
Index: l1-aprims.lisp
===================================================================
RCS file: /usr/local/tmpcvs/ccl-0.14/ccl/level-1/l1-aprims.lisp,v
retrieving revision 1.3
diff -c -r1.3 l1-aprims.lisp
*** l1-aprims.lisp 20 Dec 2003 08:40:45 -0000 1.3
--- l1-aprims.lisp 8 Jan 2004 22:16:42 -0000
***************
*** 111,116 ****
--- 111,118 ----
(defun values-list (arg)
+ (unless (typep arg 'list)
+ (report-bad-arg arg 'list))
(apply #'values arg))
-------------- next part --------------
More information about the Bug-openmcl
mailing list