From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jean Abou Samra Newsgroups: gmane.lisp.guile.devel,gmane.lisp.guile.bugs Subject: Re: simple-format vs (ice-9 format) bug in 3.0.7? Date: Tue, 27 Sep 2022 12:38:29 +0200 Message-ID: <6396d555-17fe-dc16-970b-f1075e61131a@abou-samra.fr> References: <00542b80-4511-f902-1f8d-a8c5d1645bc3@abou-samra.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28513"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.1 To: Christopher Lam , bug-guile@gnu.org, guile-devel Original-X-From: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Tue Sep 27 12:40:27 2022 Return-path: Envelope-to: guile-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1od80p-0007EG-6k for guile-devel@m.gmane-mx.org; Tue, 27 Sep 2022 12:40:27 +0200 Original-Received: from localhost ([::1]:59334 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1od80o-00038b-93 for guile-devel@m.gmane-mx.org; Tue, 27 Sep 2022 06:40:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:45856) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1od7z4-0008Ur-CB; Tue, 27 Sep 2022 06:38:41 -0400 Original-Received: from mout.kundenserver.de ([212.227.126.130]:45121) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1od7z0-0007MJ-5g; Tue, 27 Sep 2022 06:38:36 -0400 Original-Received: from [172.20.10.5] ([37.170.181.106]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.168]) with ESMTPSA (Nemesis) id 1MHGTI-1oPwhD1oUi-00DGo2; Tue, 27 Sep 2022 12:38:31 +0200 Content-Language: en-US In-Reply-To: <00542b80-4511-f902-1f8d-a8c5d1645bc3@abou-samra.fr> X-Provags-ID: V03:K1:YsXIC7rZ1jQlGkxGxI/f7kXTcGbgUcY/KtOY4w/VaiirnttIrfu jNr/6mAhqn30rmhNaXdgDUeYTA7AMmgGmTxlE8MbZ4tLKbJOT4CLwnH39k+fG1wKponxW6B ciraf4xYB0cxhwqIIygstm8tQ6ysdDOfEtg7e0WhB1Dqlcjz8wfkBNV+dUhCsOMeSFeKGY1 pJYOqc56hdl2H9AmC3ACQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:yZNXXYtmL6c=:Z9HIRHBkZQKL2XO4CPvIwi bhi0YL3DDTPkXoFh9h6dHsNPPbBjcKJzvyRIEL+llynmOObqkNSSiuEmE8sQYS9rcHcYuR7Ri MNbdtOAldZ530oiS+8xQ7mYqFwuXNvh5XoIveGKzCI1cmiQylNq+Vfn4XGOuL6PBzLUjabrUd 8VoKVgRD/1Zku9gQF6siFM295AxANJxGJ/gNbfnwfe0fL4z8Bkv2VTYssoTmIatYZtENqdzrs WGALMrmmYGIAXJJ3oh0HJ2/TZ1HXrtaBm0E/XlZqSrXqdE5YQNq/VsosM5qOXo0a1Cj+7cWc+ k03ExRZ9/NSwu9J2dQYVioBjh2j9BgGYg/V1brwozy9WjL0Rn4f7qyHjq8Vi+ZPBW9xo6dd6p ke1vnqhk8qtb+K58BIE6e22Gmz54x5uFoGv8k/mg//Z4t5ECguapKYRvRCbJ/1v0EJXOK2RF/ fyeB1mQa6hXMBYg+lyqfRjzSactZ9MvKtNOL1KgVhj1PrDPlVzHU+OsEpm73FUQn29rckTiuy qSXcZiNOa/B9njKv6NS8mfcHF8BmuCR4D4aS/u4tMwP/N76Ck02m+mfpN/UEAzvaLSaLZOHpm NoHQADTDEtglJtXLxrVYQoxPfTLK2eWq40dF5s+y7JGa5/Srz61Iclg7KK1LdJljwLNj7MW4C RhToBbmMa1aoFARMEsfC8OCcs+SXPB4K1MheGxN4j4u32W4g7Vn1YN1JJvPdAhtr1L3LZrbm4 1voThtKNAuKmNRR4JZI6WZzgDPOXjm7mwXWpNScqFI92mx1H287bvdFWTxvznceYYs7DioaK Received-SPF: none client-ip=212.227.126.130; envelope-from=jean@abou-samra.fr; helo=mout.kundenserver.de X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, NICE_REPLY_A=-2.319, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane-mx.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.io gmane.lisp.guile.devel:21373 gmane.lisp.guile.bugs:10383 Archived-At: Le 27/09/2022 à 12:35, Jean Abou Samra a écrit : > > > Le 27/09/2022 à 12:23, Christopher Lam a écrit : >> Hi guilers, here's a short bash session. >> Why would the first bash call to "guile s.scm" work, but not the >> second one? >> guile-3.0.7 on ubuntu. >> > > > This is a duplicate of > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=50059 > Uh, at the end of module/ice-9/format.scm, there is ;; Thanks to Shuji Narazaki (module-set! the-root-module 'format format) which dates back to commit 14469b7c69feb0f2c5b8a093f19fe2a548b31c5b Author: Greg J. Badros Date:   Thu Jan 20 20:58:30 2000 +0000     * format.scm: Use (variable-set! (builtin-variable 'format)) to     re-define format to be format:format (instead of just define,     which interacts poorly with the module system).  Thanks to Shuji     Narazaki for this change. diff --git a/ice-9/format.scm b/ice-9/format.scm index fce2737ce..40f20b3da 100644 --- a/ice-9/format.scm +++ b/ice-9/format.scm @@ -1670,7 +1670,9 @@  (define format:abort (lambda () (error "error in format"))) -(define format format:format) +;;(define format format:format) +;; Thanks to Shuji Narazaki +(variable-set! (builtin-variable 'format) format:format)  ;; If this is not possible then a continuation is used to recover  ;; properly from a format error. In this case format returns #f. This probably predates #:replace and could be removed now, right?