From ... From: Erik Naggum Subject: Re: debugging anonymous lambda forms Date: 1999/03/26 Message-ID: <3131451053382297@naggum.no>#1/1 X-Deja-AN: 459373255 References: <01be763a$7e1f16e0$LocalHost@ppnorn.atlant.ru> <36FA9C70.9791A372@franz.com> <7dg20f$am1@news.net-link.net> mail-copies-to: never Organization: Naggum Software; +47 8800 8879; http://www.naggum.no Newsgroups: comp.lang.lisp * "Will Fitzgerald" | based on a comment--I think by Olin Shivers in discussions about a | standard list library for Scheme--that when you see a predicate like EQL | embedded in a function, you're not capturing the right abstraction--it's | like having any other constant embedded in your function. Scheme has to do it that way because it has so weak lambda lists, with neither optional nor keyword arguments, and no macro system to build them, either. I prefer to use KEY and TEST keyword arguments that default to #'IDENTITY and #'EQL. (defun duplic8 (element list &key (test #'eql) (key #'identity)) (loop for x in list collect x when (funcall test (funcall key x) element) collect x)) incidentally, "any other constant embedded in your function" does not sound like a real argument, since functions by their very nature must have a number of constants. #:Erik