[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

case using other equality-testing predicates



Regardless of whether your particular application does or does not need
it, I too have long wanted to be able to specify the test function in
CASE.  In Symbolics Common Lisp we have this as an alternate function
name.  I'm sure some people will jump all over me for suggesting this,
but it might be better to allow CASE to accept a :TEST keyword.  Which
of these three syntaxes do you-all prefer?

  (selector item equalp ("foo" ...) ...)

  (case item :test #'equalp ("foo" ...) ...)

  (cond ((equalp item "foo") ...) ...)