This is the mail archive of the guile@cygnus.com mailing list for the guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: backslashes in /etc/termcap


> 
> The entries in /etc/termcap contain tons of backslashes which are mis-
> interpreted by scheme. Is there any possibility at all. In this way writing
> tgetent,tgetstr and tputs (from libtermcap) in Guile doesn't have a snowball's
> chance in hell to work. Is there a way to get around the backslash-dilemma
> for handling the termcaps?
> 

One of us is missing the point.  The (read) procedure in Scheme reads Scheme
objects from a file, but nobody ever said /etc/termcap was a file of Scheme
objects.  If you want to read characters from a file, use (read-char).
This procedure returns characters just as they are, without any escape
sequences.  Guile also has (read-line) if you want the whole line.

-- 
     --Keith

This mail message sent by GNU emacs and Linux.
Power to the people. Linux is here.
Food, Shelter, Source code.