This is the mail archive of the
guile@sourceware.cygnus.com
mailing list for the Guile project.
Re: Error in block comments
- To: guile at sourceware dot cygnus dot com
- Subject: Re: Error in block comments
- From: Chris Cramer <crayc at kiwi dot pyro dot net>
- Date: Sat, 29 Apr 2000 19:08:40 -0500
- References: <200004251937.VAA24931@faun.cs.tu-berlin.de>
On Tue, Apr 25, 2000 at 09:37:46PM +0200, Martin Grabmueller wrote:
> it seems Guile is not parsing block comments correctly, but I am not sure
> whether it is by specification rather than by error. Consider the following
> test:
>
> mgrabmue@tortoise (~): guile
> guile> '(#!
> ... !#
> ... )
> ERROR: In procedure read:
> ERROR: unexpected ")"
> ABORT: (misc-error)
> guile>
>
> Block comments are not ignored inside of list and vector literals. I would
> call this a bug but I recall having read something about `block comments are
> only allowed at the beginning of script files'. I don't know where I read
> that though. Please enlighten me who is mistaken: the interpreter or me.
OK, I looked at the code and it seems like you are wrong. Guile checks for
'\n!#\n' to end a block comment, so !# needs to be on a line by itself. I
can't find where the syntax for block comments is documented however. I'm not exactly sure what the syntax is, I try things like:
'(#!
!#
)
and they don't work. This is not intuitive to those of us familiar with
C-style comments. =^P Maybe the code is wrong, I dunno... need to go
find the scsh manual.
--
C. Ray C. aka Christopher Cramer
crayc@pyro.net
http://www.pyro.net/~crayc/