GNU bug report logs - #39601
srfi library naming in r7rs

Previous Next

Package: guile;

Reported by: Duy Nguyen <pclouds <at> gmail.com>

Date: Fri, 14 Feb 2020 15:09:02 UTC

Severity: normal

Tags: patch

Done: lloda <lloda <at> sarc.name>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 39601 in the body.
You can then email your comments to 39601 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guile <at> gnu.org:
bug#39601; Package guile. (Fri, 14 Feb 2020 15:09:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Duy Nguyen <pclouds <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Fri, 14 Feb 2020 15:09:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Duy Nguyen <pclouds <at> gmail.com>
To: bug-guile <at> gnu.org
Subject: srfi library naming in r7rs
Date: Fri, 14 Feb 2020 21:48:20 +0700
I'm running Guile 3.0.0 and very new to Guile. Forgive me if this is
not the right place to report (or whether I should do more search,
where?, before reporting)

It seems like in r7rs mode, srfi libraries are still named in "Guile
style", (srfi srfi-1). I can't find a place in r7rs-small to spell out
"srfi followed by a number". But it seems every other r7rs scheme goes
with (srfi 1) instead. Should Guile support this naming convention as
well? It certainly makes it easier to reuse external libraries.
-- 
Duy




Information forwarded to bug-guile <at> gnu.org:
bug#39601; Package guile. (Sat, 15 May 2021 17:45:02 GMT) Full text and rfc822 format available.

Message #8 received at 39601 <at> debbugs.gnu.org (full text, mbox):

From: Taylan Kammer <taylan.kammer <at> gmail.com>
To: 39601 <at> debbugs.gnu.org, Duy Nguyen <pclouds <at> gmail.com>
Subject: srfi library naming in r7rs
Date: Sat, 15 May 2021 19:44:04 +0200
[Message part 1 (text/plain, inline)]
Tag: patch


Hi,

For sake of having it documented here as well, attached is a patch
that implements a fix to this issue, that I recently sent to the
guile-devel mailing list.

Copying from the commit message:

It was already possible to import an SRFI module by referencing it
as (srfi :n) which is automatically translated to (srfi srfi-n), but
this conversion was only done during import.  After this change, it's
also possible to define a library as (srfi :n) which is automatically
translated to (srfi srfi-n) during definition.

It was not possible at all to define or import SRFI module names in the
R7RS format, (srfi n), where n is a non-negative exact integer.  It is
now possible both to define and import them as such, realized through
the same kind of conversion to a canonical (srfi srfi-n) name.


--
Taylan
[0001-Improve-support-for-R6-R7-SRFI-module-name-formats.patch (text/plain, attachment)]

Added tag(s) patch. Request was from Taylan Kammer <taylan.kammer <at> gmail.com> to control <at> debbugs.gnu.org. (Sat, 15 May 2021 17:48:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-guile <at> gnu.org:
bug#39601; Package guile. (Mon, 01 Nov 2021 17:53:01 GMT) Full text and rfc822 format available.

Message #13 received at 39601 <at> debbugs.gnu.org (full text, mbox):

From: lloda <lloda <at> sarc.name>
To: Taylan Kammer <taylan.kammer <at> gmail.com>
Cc: 39601 <at> debbugs.gnu.org, pclouds <at> gmail.com
Subject: Re: bug#39601: srfi library naming in r7rs
Date: Mon, 1 Nov 2021 18:52:17 +0100
Hi Taylan,

Your patch leaks a bunch of identifiers, could you fix that?

thanks

	Daniel





Information forwarded to bug-guile <at> gnu.org:
bug#39601; Package guile. (Mon, 01 Nov 2021 18:43:02 GMT) Full text and rfc822 format available.

Message #16 received at 39601 <at> debbugs.gnu.org (full text, mbox):

From: Taylan Kammer <taylan.kammer <at> gmail.com>
To: lloda <lloda <at> sarc.name>
Cc: 39601 <at> debbugs.gnu.org, pclouds <at> gmail.com
Subject: Re: bug#39601: srfi library naming in r7rs
Date: Mon, 1 Nov 2021 19:42:01 +0100
[Message part 1 (text/plain, inline)]
On 01.11.2021 18:52, lloda wrote:
> 
> Hi Taylan,
> 
> Your patch leaks a bunch of identifiers, could you fix that?
> 
> thanks
> 
> 	Daniel
> 

Apparently anything defined in boot-9 is implicitly made public in
the (guile) module, I wasn't aware of that.

Is there a work-around that allows one to define helpers that can
be used by multiple definitions?

Attached is a naive fix that duplicates a bunch of helpers which is
not very nice.

-- 
Taylan
[0001-Improve-support-for-R6-R7-SRFI-module-name-formats.patch (text/plain, attachment)]

Reply sent to lloda <lloda <at> sarc.name>:
You have taken responsibility. (Tue, 02 Nov 2021 17:54:02 GMT) Full text and rfc822 format available.

Notification sent to Duy Nguyen <pclouds <at> gmail.com>:
bug acknowledged by developer. (Tue, 02 Nov 2021 17:54:02 GMT) Full text and rfc822 format available.

Message #21 received at 39601-done <at> debbugs.gnu.org (full text, mbox):

From: lloda <lloda <at> sarc.name>
To: Taylan Kammer <taylan.kammer <at> gmail.com>
Cc: 39601-done <at> debbugs.gnu.org, pclouds <at> gmail.com
Subject: Re: bug#39601: srfi library naming in r7rs
Date: Tue, 2 Nov 2021 18:53:10 +0100
Applied in a960d7869bc82bb56d5446ece01b8efff9b15fef. Thank you!





Information forwarded to bug-guile <at> gnu.org:
bug#39601; Package guile. (Wed, 03 Nov 2021 07:39:01 GMT) Full text and rfc822 format available.

Message #24 received at 39601 <at> debbugs.gnu.org (full text, mbox):

From: Linus Björnstam <linus.bjornstam <at> veryfast.biz>
To: "Taylan Kammer" <taylan.kammer <at> gmail.com>, lloda <lloda <at> sarc.name>
Cc: 39601 <at> debbugs.gnu.org, pclouds <at> gmail.com
Subject: Re: bug#39601: srfi library naming in r7rs
Date: Wed, 03 Nov 2021 08:37:30 +0100
Well, as someone who has written a lot of macros https://srfi.schemers.org/srfi-206/ is a fantastic utility SRFI. It allows several libraries to define the same aux syntax (say like srfi-26's <>) without having collisions.

That is not strictly what you were looking for if I understand the patch correctly, though.

-- 
  Linus Björnstam

On Mon, 1 Nov 2021, at 19:42, Taylan Kammer wrote:
> On 01.11.2021 18:52, lloda wrote:
>> 
>> Hi Taylan,
>> 
>> Your patch leaks a bunch of identifiers, could you fix that?
>> 
>> thanks
>> 
>> 	Daniel
>> 
>
> Apparently anything defined in boot-9 is implicitly made public in
> the (guile) module, I wasn't aware of that.
>
> Is there a work-around that allows one to define helpers that can
> be used by multiple definitions?
>
> Attached is a naive fix that duplicates a bunch of helpers which is
> not very nice.
>
> -- 
> Taylan
> Attachments:
> * 0001-Improve-support-for-R6-R7-SRFI-module-name-formats.patch




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 01 Dec 2021 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 139 days ago.

Previous Next


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