From: Maxime Devos <maximedevos@telenet.be>
To: Jean Abou Samra <jean@abou-samra.fr>, Paul Jarc <prj@case.edu>,
guile-user@gnu.org
Subject: Re: defining macros within eval
Date: Sun, 16 Oct 2022 18:21:30 +0200 [thread overview]
Message-ID: <62551ceb-5c3c-24e9-a119-aa4347c96734@telenet.be> (raw)
In-Reply-To: <966a9085-bc84-c53f-56ac-812ddf9d60b5@abou-samra.fr>
[-- Attachment #1.1.1: Type: text/plain, Size: 758 bytes --]
On 16-10-2022 16:07, Jean Abou Samra wrote:
>
>> Is there some way to make this work? In my real code,
>> the expression is read from a file, where it might be a macro
>> definition or anything else, and it's evaluated in a different module
>> from the current one.
>
>
> You cannot byte-compile code in advance if it uses macros that
> are only known dynamically. [...]
Possibly in Paul Jarc's case, while they the macros might be computed,
they might also be the same between runs of "guile -l do-something.scm".
If that's the case (i.e., the expression read from the file remains
unchanged), byte compiling is possible, just use eval-when, see my reply.
Greetings,
Maxime.
[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 929 bytes --]
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 236 bytes --]
next prev parent reply other threads:[~2022-10-16 16:21 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-16 9:39 defining macros within eval Paul Jarc
2022-10-16 14:07 ` Jean Abou Samra
2022-10-16 16:21 ` Maxime Devos [this message]
2022-10-16 16:13 ` Maxime Devos
2022-10-16 16:17 ` Maxime Devos
2022-10-19 8:42 ` Paul Jarc
2022-10-19 17:36 ` 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=62551ceb-5c3c-24e9-a119-aa4347c96734@telenet.be \
--to=maximedevos@telenet.be \
--cc=guile-user@gnu.org \
--cc=jean@abou-samra.fr \
--cc=prj@case.edu \
/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).