From b63537a8cc7c8e65609889725a2a3b81b0bb3750 Mon Sep 17 00:00:00 2001 From: Alex Shinn Date: Sat, 15 Dec 2012 10:26:11 +0900 Subject: [PATCH] Signalling error on '(x . .) read syntax. --- sexp.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sexp.c b/sexp.c index ecc3da16..662ab4b8 100644 --- a/sexp.c +++ b/sexp.c @@ -2638,6 +2638,9 @@ sexp sexp_read_raw (sexp ctx, sexp in) { } else if (sexp_read_raw(ctx, in) != SEXP_CLOSE) { res = sexp_read_error(ctx, "multiple tokens in dotted tail", SEXP_NULL, in); + } else if (tmp == SEXP_RAWDOT) { + res = sexp_read_error(ctx, "multiple dots in list", + SEXP_NULL, in); } else { tmp2 = res; res = sexp_nreverse(ctx, res);