unofficial mirror of bug-guile@gnu.org 
 help / color / mirror / Atom feed
From: Mark H Weaver <mhw@netris.org>
To: Andy Wingo <wingo@pobox.com>
Cc: 38236@debbugs.gnu.org
Subject: bug#38236: R7RS reader does not support datum labels
Date: Mon, 18 Nov 2019 10:10:30 -0500	[thread overview]
Message-ID: <87ftil5if2.fsf@netris.org> (raw)
In-Reply-To: <87pnhrmtrc.fsf@pobox.com> (Andy Wingo's message of "Sat, 16 Nov 2019 21:49:27 +0100")

Hi Andy,

Andy Wingo <wingo@pobox.com> writes:

> R7RS defines a lexical feature called "datum labels"; see section 2.4 in
> the report.  An example would be:
>
>    #0=(a b c . #0#)
>
> Guile's reader doesn't support this feature and it's not clear if we
> should, in general.

FYI, I already implemented R7RS datum labels on the 'r7rs-wip' branch
(not to be confused with your new 'wip-r7rs' branch):

  https://git.savannah.gnu.org/cgit/guile.git/commit/?h=r7rs-wip&id=92408ac20e921583b8e4ee26463dc5805ef01153

It depends on the preceding commit on the same branch:

  https://git.savannah.gnu.org/cgit/guile.git/commit/?h=r7rs-wip&id=f687871eceb94bded109569880e696d8862d84fd

There was also a later commit on that branch that enabled compilation of
cyclic literals, but it's no longer applicable to the 'master' branch.

> Note, datum literals appear to be incompatible with array literals.

Can you elaborate on why you believe they're incompatible?  I haven't
looked closely in a while, but I didn't see any incompatibility when I
implemented this before.  Datum labels have '#' or '=' after the
numeral, and I'm not aware of any Guile array syntax that does.

I'm also a bit puzzled why you're apparently planning to rewrite
everything I already did on the 'r7rs-wip' branch.  The main issue on
that branch is that the implementation of *writing* cyclic data turned
out to be a mess, but it could be removed or replaced without affecting
much else.

       Mark





  parent reply	other threads:[~2019-11-18 15:10 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-11-16 20:49 bug#38236: R7RS reader does not support datum labels Andy Wingo
2019-11-16 22:41 ` John Cowan
2019-11-18 15:10 ` Mark H Weaver [this message]
2019-11-18 18:35   ` Andy Wingo
2019-11-18 20:57     ` Arne Babenhauserheide

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/guile/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ftil5if2.fsf@netris.org \
    --to=mhw@netris.org \
    --cc=38236@debbugs.gnu.org \
    --cc=wingo@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).