GNU bug report logs - #30600
repl metacommands do not discard remaining input after syntax error in an expression

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: guile; Reported by: dikbekulo@HIDDEN; Keywords: patch; dated Sun, 25 Feb 2018 00:51:01 UTC; Maintainer for guile is bug-guile@HIDDEN.
Added tag(s) patch. Request was from Taylan Kammer <taylan.kammer@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 30600 <at> debbugs.gnu.org:


Received: (at 30600) by debbugs.gnu.org; 18 May 2021 16:19:42 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue May 18 12:19:42 2021
Received: from localhost ([127.0.0.1]:57075 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1lj2RZ-0002Ja-Um
	for submit <at> debbugs.gnu.org; Tue, 18 May 2021 12:19:42 -0400
Received: from mail-ej1-f51.google.com ([209.85.218.51]:35472)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <taylan.kammer@HIDDEN>) id 1lj2RY-0002JM-74
 for 30600 <at> debbugs.gnu.org; Tue, 18 May 2021 12:19:40 -0400
Received: by mail-ej1-f51.google.com with SMTP id k14so12007595eji.2
 for <30600 <at> debbugs.gnu.org>; Tue, 18 May 2021 09:19:40 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=to:from:subject:message-id:date:user-agent:mime-version
 :content-language;
 bh=aFMS6q+f67JNGgzX71dwfPKWpBGon3ckxJvFWJ3E+XM=;
 b=O39NMTdryzsq/JW2Zg60Usi+Rj1Tq1bTvxrsil3tzGFH4bMlnAFYONjllOJjQ9YM/P
 vBgeQ+nN0iTg3L4HFaoBeZueS8RLrODbO3FoXSibE/RmkX5bX2eUrACRf0Tg5F+bxNcN
 ddLocQQTbMFIixh7gxetng3FfagPbcSWbHDZhtz8O4mUtTCGpSfKgPDFSd0I1qHNlWk9
 dtUZJ/gjOostSJzmz4V4541httJ63bFYmMzC8LoYPBFoOo5rGENHeisNcu6YgDXnWNAW
 kgDgi/nZz+Ycd7U1V5ULJeBGxOwcUNLirJ1UMLWJzSTnSDih3kImsoFBy+hFKREuPgop
 z0Mg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:to:from:subject:message-id:date:user-agent
 :mime-version:content-language;
 bh=aFMS6q+f67JNGgzX71dwfPKWpBGon3ckxJvFWJ3E+XM=;
 b=IL4PygKWWNQb7odHsdhtayi4FR0F5Id/puq5PyaqBz8PdApJWCxz1zbpnZmK2jSN/R
 jX8PMiXdtFb8K3hiT9Mkzb0GQKiVSm+BEHafToo9+8+mXyyL04djyYO+o6pUfLsQDfVw
 UcOY1Om2MHdwLolsmYCa2DNyXmLXx3BK1Z6xlLsbxrPjf29Hd4uf6s9NPyMbTsC5lI69
 DqGp18W9ctx4jS+sqa7vHfyr+0MNBKZcKR298BeiH8MgrLrB+hCZKaykFEisml3fiQGb
 mMErMvn5/VSvrrnH9wiMST/Q0D4l0Iv9pz1JHaN72nwgSuUlwXT5JgZFV7+cCf3UtVIJ
 fqng==
X-Gm-Message-State: AOAM530tGUpa8zAATVcppMRPrp7bvEYh3BcmH4gWxpWpHdlUZVTdlZIK
 qKQf6HQAcdewPNzxpu+d3xSx97kcHzy19w==
X-Google-Smtp-Source: ABdhPJw6SVBvZOgjiU7WazIG2anfuVqcOm8oofp2PxY6UUO75TkISUh6hXoqv995hH/1dGimKquSpw==
X-Received: by 2002:a17:906:a3c9:: with SMTP id
 ca9mr6868967ejb.553.1621354774355; 
 Tue, 18 May 2021 09:19:34 -0700 (PDT)
Received: from [192.168.178.20] (b2b-109-90-125-150.unitymedia.biz.
 [109.90.125.150])
 by smtp.gmail.com with ESMTPSA id f7sm13598192edd.5.2021.05.18.09.19.33
 for <30600 <at> debbugs.gnu.org>
 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
 Tue, 18 May 2021 09:19:33 -0700 (PDT)
To: 30600 <at> debbugs.gnu.org
From: Taylan Kammer <taylan.kammer@HIDDEN>
Subject: repl metacommands do not discard remaining input after syntax error
 in an expression
Message-ID: <0362f51c-6659-55f8-c3c0-02d4a63773b7@HIDDEN>
Date: Tue, 18 May 2021 18:19:30 +0200
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101
 Thunderbird/78.10.1
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="------------F602583569526E8F609D7E0C"
Content-Language: en-US
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 30600
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

This is a multi-part message in MIME format.
--------------F602583569526E8F609D7E0C
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit

Attached is a small patch to fix this.

-- 
Taylan

--------------F602583569526E8F609D7E0C
Content-Type: text/plain; charset=UTF-8;
 name="0001-Better-REPL-behavior-on-syntax-errors-in-meta-comman.patch"
Content-Transfer-Encoding: base64
Content-Disposition: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2
IEBACiAgICAgICAgICAgICAgICAgICp1bnNwZWNpZmllZCopCiAgICAgICAgICAgICAgICAg
KGVsc2UgKChsYW5ndWFnZS1yZWFkZXIgbGFuZykgcG9ydCBlbnYpKSkpKSkpKQogICAgICAg
ICAKLShkZWZpbmUgKGZsdXNoLWFsbC1pbnB1dCkKLSAgKGlmIChhbmQgKGNoYXItcmVhZHk/
KQotICAgICAgICAgICAobm90IChlb2Ytb2JqZWN0PyAocGVlay1jaGFyKSkpKQotICAgICAg
KGJlZ2luCi0gICAgICAgIChyZWFkLWNoYXIpCi0gICAgICAgIChmbHVzaC1hbGwtaW5wdXQp
KSkpCi0KIDs7IHJlcGwtcmVhZGVyIGlzIGEgZnVuY3Rpb24gZGVmaW5lZCBpbiBib290LTku
c2NtLCBhbmQgaXMgcmVwbGFjZWQgYnkKIDs7IHNvbWV0aGluZyBlbHNlIGlmIHJlYWRsaW5l
IGhhcyBiZWVuIGFjdGl2YXRlZC4gbXVjaCBvZiB0aGlzIGhvb3BsYSBpcwogOzsgdG8gYmUg
YWJsZSB0byByZS11c2UgdGhlIGV4aXN0aW5nIHJlYWRsaW5lIG1hY2hpbmVyeS4KLS0gCjIu
MzAuMgoK
--------------F602583569526E8F609D7E0C--




Information forwarded to bug-guile@HIDDEN:
bug#30600; Package guile. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 25 Feb 2018 00:50:28 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Feb 24 19:50:28 2018
Received: from localhost ([127.0.0.1]:59303 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1epkWJ-00057R-Cl
	for submit <at> debbugs.gnu.org; Sat, 24 Feb 2018 19:50:28 -0500
Received: from eggs.gnu.org ([208.118.235.92]:53163)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <dikbekulo@HIDDEN>) id 1epjHz-0003EY-Iq
 for submit <at> debbugs.gnu.org; Sat, 24 Feb 2018 18:31:36 -0500
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <dikbekulo@HIDDEN>) id 1epjHt-0006Aq-MH
 for submit <at> debbugs.gnu.org; Sat, 24 Feb 2018 18:31:30 -0500
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,T_DKIM_INVALID
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:46527)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <dikbekulo@HIDDEN>)
 id 1epjHt-0006Ah-J6
 for submit <at> debbugs.gnu.org; Sat, 24 Feb 2018 18:31:29 -0500
Received: from eggs.gnu.org ([2001:4830:134:3::10]:44132)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <dikbekulo@HIDDEN>) id 1epjHs-0005nk-Fs
 for bug-guile@HIDDEN; Sat, 24 Feb 2018 18:31:29 -0500
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <dikbekulo@HIDDEN>) id 1epjHn-00060b-JJ
 for bug-guile@HIDDEN; Sat, 24 Feb 2018 18:31:28 -0500
Received: from cock.li ([185.100.85.212]:36458)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <dikbekulo@HIDDEN>)
 id 1epjHn-0005wB-7C
 for bug-guile@HIDDEN; Sat, 24 Feb 2018 18:31:23 -0500
MIME-Version: 1.0
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=airmail.cc; s=mail;
 t=1519515080; bh=iPf7spF2Er5FXmIeah8nwihr3t8e8NxXJ3iIvzX0C3E=;
 h=Date:From:To:Subject:From;
 b=sJU6dOmYFyhFQ47/q1Sn6xzY7tHHcu/gyUsQfckSyOW28YYoIT4NyEnGJz30zuUNt
 pP8GZGsN36uBGjWnpGKrj5PY4EA5kfQa3stt8gBAU1qrpRTDbIbgyshS4pieOD69kq
 LLtOyR3zH0wacrjL8IdAIzzN8Q981uKEOVzfZXeqYa5cvXZbr4yTZujMdOPyaoPeBj
 vsXQSb/KwLEdUDMfvRAYJKzj5NOLHATnqBmJDYm0pG1MZpeyDYyKvkjLR5ffsJXVPI
 m9sTr2okCRqER1cI0VRZEVLXrtt6TFcD2UpEoHhaD8pLxsQeTDY5hFEzpPE7l9CBpo
 HRBq1xjj+ZL3Q==
Content-Type: text/plain; charset=US-ASCII;
 format=flowed
Content-Transfer-Encoding: 7bit
Date: Sun, 25 Feb 2018 00:31:19 +0100
From: dikbekulo@HIDDEN
To: bug-guile@HIDDEN
Subject: repl metacommands do not discard remaining input after syntax error
 in an expression
Message-ID: <c468d921644b4fd5d19fbede4a0b1d89@HIDDEN>
X-Sender: dikbekulo@HIDDEN
User-Agent: Roundcube Webmail/1.3.3
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
 [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -4.1 (----)
X-Debbugs-Envelope-To: submit
X-Mailman-Approved-At: Sat, 24 Feb 2018 19:50:26 -0500
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.1 (----)

Hello!

When using meta-commands in the repl (without readline support), if 
reading an expression parameter fails, the rest of the input gets read 
in anyway. An example interaction:

--8<---------------cut here---------------start------------->8---
GNU Guile 2.2.3
Copyright (C) 1995-2017 Free Software Foundation, Inc.

Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
This program is free software, and you are welcome to redistribute it
under certain conditions; type `,show c' for details.

Enter `,help' for help.
scheme@(guile-user)> ,trace "\m"
Throw to key `read-error' while reading argument `form' of command 
`trace':
In procedure scm_lreadr: #<unknown port>:1:11: illegal character in 
escape sequence: #\m
"
$1 = "\n"
scheme@(guile-user)> ,trace "\m123
Throw to key `read-error' while reading argument `form' of command 
`trace':
In procedure scm_lreadr: #<unknown port>:2:11: illegal character in 
escape sequence: #\m
$2 = 123
--8<---------------cut here---------------end--------------->8---

Since Geiser uses meta-commands with multi-line expressions to 
communicate with Guile it can get very confusing if you have syntax 
errors in your code.




Acknowledgement sent to dikbekulo@HIDDEN:
New bug report received and forwarded. Copy sent to bug-guile@HIDDEN. Full text available.
Report forwarded to bug-guile@HIDDEN:
bug#30600; Package guile. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Tue, 18 May 2021 16:30:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.