<aguerrahdz@yahoo.com> wrote:
+---------------
| kt is right, I've tried without apply, but keeping the &rest thing with
| ,@ and backquote:
|
| (defun string-append0 (&rest strings)
| (declare (optimize (speed 3) (safety 0)))
| `(concatenate 'string ,@strings))
+---------------
Surely this is a typo, yes? As Ken pointed out, the result of
the above is a list, *not* a string. Perhaps you meant this?
(defmacro string-append0 (&rest strings)
`(concatenate 'string ,@strings))
I've been using something similar in my personal UTILS package:
(defun strcat (&rest strings)
(apply #'concatenate 'string strings))
;;; If arity known at compile time, semi-inline it.
(define-compiler-macro strcat (&rest strings)
`(concatenate 'string ,@strings))
-Rob
-----
Rob Warnock <rpw3@rpw3.org>
627 26th Avenue <URL:http://rpw3.org/>
San Mateo, CA 94403 (650)572-2607