1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-12 06:41:13 +02:00

* read.c (scm_lreadr): Encountering EOF after skipping a SCSH

style block comment is no longer considered an error.
This commit is contained in:
Marius Vollmer 1996-12-29 10:37:58 +00:00
parent 4ecd21bc8c
commit b6356af70f

View file

@ -283,6 +283,7 @@ scm_lreadr (tok_buf, port, case_i, sharp, copy)
tryagain: tryagain:
c = scm_flush_ws (port, s_read); c = scm_flush_ws (port, s_read);
tryagain_no_flush_ws:
switch (c) switch (c)
{ {
case EOF: case EOF:
@ -363,7 +364,9 @@ tryagain:
/* start of a shell script. Parse as a block comment, /* start of a shell script. Parse as a block comment,
terminated by !#, just like SCSH. */ terminated by !#, just like SCSH. */
skip_scsh_block_comment (port); skip_scsh_block_comment (port);
goto tryagain; /* EOF is not an error here */
c = scm_flush_ws (port, (char *)NULL);
goto tryagain_no_flush_ws;
case '*': case '*':
j = scm_read_token (c, tok_buf, port, case_i, 0); j = scm_read_token (c, tok_buf, port, case_i, 0);