|
From: | Han-Wen Nienhuys |
Subject: | Re: Getting source location information |
Date: | Thu, 01 Dec 2005 00:45:24 +0100 |
User-agent: | Mozilla Thunderbird 1.0.7-1.1.fc4 (X11/20050929) |
Bruce Korb wrote:
Hi, I am completely certain that this makes sense to you. To me, it does not. If I call ``scm_read(port)'' I have to attach the input file as a port. That read function reads an s-expr. How can that work if the non-Scheme text in the file is not an s-expr? I don't see another
What we do in LilyPond is to do scm_seek() to the start of the s-expr. Then scm_read() reads exactly one s-expr, and scm_ftell() shows us where we can continue reading non-Scheme stuff. The port is a string-port, which is easy enough, as we read the input file in a big string anyway.
-- Han-Wen Nienhuys - address@hidden - http://www.xs4all.nl/~hanwen
[Prev in Thread] | Current Thread | [Next in Thread] |