mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-22 04:30:19 +02:00
need read error for extra closing square brackets
* libguile/read.c (scm_read_expression): add test
This commit is contained in:
parent
5bae880e26
commit
a4e4722944
1 changed files with 4 additions and 0 deletions
|
@ -1442,6 +1442,10 @@ scm_read_expression (SCM port)
|
||||||
case ')':
|
case ')':
|
||||||
scm_i_input_error (FUNC_NAME, port, "unexpected \")\"", SCM_EOL);
|
scm_i_input_error (FUNC_NAME, port, "unexpected \")\"", SCM_EOL);
|
||||||
break;
|
break;
|
||||||
|
case ']':
|
||||||
|
if (SCM_SQUARE_BRACKETS_P)
|
||||||
|
scm_i_input_error (FUNC_NAME, port, "unexpected \"]\"", SCM_EOL);
|
||||||
|
/* otherwise fall through */
|
||||||
case EOF:
|
case EOF:
|
||||||
return SCM_EOF_VAL;
|
return SCM_EOF_VAL;
|
||||||
case ':':
|
case ':':
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue