unofficial mirror of guile-devel@gnu.org 
 help / color / mirror / Atom feed
From: "Ludovic Courtès" <ludo@gnu.org>
To: guile-devel@gnu.org
Subject: Re: [PATCH] Print backtraces for syntax errors too.
Date: Thu, 23 Feb 2023 12:38:33 +0100	[thread overview]
Message-ID: <87pma07gsm.fsf@gnu.org> (raw)
In-Reply-To: 20230208155905.27194-1-maximedevos@telenet.be

Hi,

Maxime Devos <maximedevos@telenet.be> skribis:

> For complicated macros, especially macros that are used correctly but
> have a bug in their implementation somewhere and use 'syntax-case'
> or 'syntax-rules' multiple times, it can be very convenient to know
> _which_ syntax-case or syntax-rules raised the syntax-error.
>
> E.g., I'm currently debugging some changes to a (non-Guile) macro,
> and I don't know what to make of the following -- the '#:getter . datum-type'
> isn't even present in the original code anywhere:
>
> ice-9/boot-9.scm:1685:16: In procedure raise-exception:
> Syntax error:
> unknown location: source expression failed to match any pattern in form (#:getter . datum-type)
> make: *** [Makefile:1333: gnu/gnunet/dht/client.go] Fout 1
>
> As such, partially revert the following commit that does not give a
> rationale on how backtraces for syntax errors aren't helpful.

Do you have a simple reproducer and a before/after comparison showing
what Guile prints?

Thanks,
Ludo’.




  reply	other threads:[~2023-02-23 11:38 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-08 15:59 [PATCH] Print backtraces for syntax errors too Maxime Devos
2023-02-23 11:38 ` Ludovic Courtès [this message]
2023-02-23 19:04   ` Maxime Devos
2023-02-23 19:10   ` Maxime Devos
2023-02-23 19:27   ` Maxime Devos
2023-02-24 15:48     ` Ludovic Courtès
2023-02-24 23:38       ` Maxime Devos

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=87pma07gsm.fsf@gnu.org \
    --to=ludo@gnu.org \
    --cc=guile-devel@gnu.org \
    /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).