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

#\| reader macro ?



In MCL 2.0.1 is there any possibility of binding a read macro to #\| (the
vertical bar)? Though it is possible to redefine its syntax to be a consti-
tuent, none of my tries to let it call a function did work. Am I missing 
something? Any help is appreciated.

Code:

> (defun bar-reader (char stream)
    (read-char stream)
    (values :seperator))
;Compiler warnings :
;   Unused lexical variable CHAR, in BAR-READER.
BAR-READER
? (set-macro-character #\| #'bar-reader)
T
? '(foo |
> Error: #\| is not capable of input
> While executing: #<STANDARD-METHOD STREAM-TYI (T)>
> Type Command-. to abort.
See the Restarts
 bar)
1 > 

------------------------------------------------------------------------------
Frank Steinle                                 Email: frank@cogpsy.uni-trier.de
Uni. Trier                                         
FB I - Psychologie (D 410)                          Phone: +49-(0)651-201-2963
D-54286 Trier                                       Fax:   +49-(0)651-201-2955
Germany
------------------------------------------------------------------------------