When CL-Interpol is too big for your needs…
…you can use this port of Perl’s qq to lisp:
(defun |#q-reader| (stream sub-char numarg) (declare (ignore sub-char numarg)) (let ((terminator (read-char stream))) (loop for ch = (read-char stream) until (eql ch terminator) collect ch into chars finally (return (coerce chars 'string))))) (set-dispatch-macro-character #\# #\q #'|#q-reader|)
More information in Space Station Lambda.
You can find CL-INTERPOL in Edi Weitz’s website.
No comments
Jump to comment form | comments rss [?] | trackback uri [?]