From: Ihor Radchenko <yantar92@posteo.net>
To: Zelphir Kaltstahl <zelphirkaltstahl@posteo.de>
Cc: Bruno Barbier <brubar.cs@gmail.com>,
emacs-orgmode@gnu.org, Bastien <bzg@gnu.org>
Subject: Re: [PATCH] lisp/ob-scheme.el
Date: Wed, 22 Mar 2023 10:43:27 +0000 [thread overview]
Message-ID: <87edphoyls.fsf@localhost> (raw)
In-Reply-To: <9710552a-601b-8a0c-1c30-4bb2263c2739@posteo.de>
Zelphir Kaltstahl <zelphirkaltstahl@posteo.de> writes:
> I've created a patch, which I will attach to this e-mail.
Thanks!
> Not sure it meets all formalities. For example it is not clear to me, whether I
> should add the "TINYCHANGE" at the bottom of my commit message.
You should, unless you have FSF copyright assignment.
> Let me know, if this an OK patch or what else needs to be done or what format is
> wrong, if any.
See my (minor) comments below.
> --
> repositories: https://notabug.org/ZelphirKaltstahl
> From 51b299aa18e882681dd681acb51c9cb1b44f3b4e Mon Sep 17 00:00:00 2001
> From: Zelphir Kaltstahl <zelphirkaltstahl@posteo.de>
> Date: Sat, 18 Mar 2023 16:06:05 +0100
> Subject: [PATCH] lisp/ob-scheme.el:
Please provide a short commit summary, not just the changed file.
See how we do it in https://git.savannah.gnu.org/cgit/emacs/org-mode.git/log/
> Wrapping binding definitions using `let' can lead to issues with GNU
> Guile and potentially other Scheme dialects. GNU Guile will only get
> to the body of the let at evaluation time, not at macro expansion
> time. If the let form wraps any imports of libraries that define
> macros, then those imported macros are seen too late and their
> corresponding forms inside the body of the let are not
> expanded. Using `define' to define bindings avoids this problem, at
> least in GNU Guile.
Please use double space between sentences. Also, it would be helpful to
provide a link to this thread for more context. (The aim of commit
message is a note for future contributors on the reason the change was
made).
> +(defun org-babel-expand-header-arg-vars:scheme (vars)
Please use org-babel-scheme-... function name. It is the usual
Elisp convention to prefix the functions as
library-name-inner-function-name.
The exception in org-babel is a set of special functions that must have
certain name pattern. Expanding header args is not one of those special
functions.
> + "Expand :var header arguments given as VARS."
> + (mapconcat
> + (lambda (var)
> + (format "(define %s %S)" (car var) (cdr var)))
Is there any reason why you use %s for variable name? Previously it was
formatted with escapes (using %S).
Also, previous version quoted the variable value with "'". Why didn't
you do it here?
> + (concat (org-babel-expand-header-arg-vars:scheme vars) body))
`mapconcat' you used in `org-babel-expand-header-arg-vars:scheme' does
not add trailing newline, unlike done previously.
--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>
next prev parent reply other threads:[~2023-03-22 10:42 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-07 11:27 org-babel guile source block bug in handling multiple values Zelphir Kaltstahl
2023-03-07 14:36 ` Ihor Radchenko
2023-03-07 15:18 ` Zelphir Kaltstahl
2023-03-07 19:52 ` Bruno Barbier
2023-03-08 0:55 ` Zelphir Kaltstahl
2023-03-08 19:38 ` Bruno Barbier
2023-03-09 0:44 ` Zelphir Kaltstahl
2023-03-09 13:04 ` [BUG] Inconsistent global/local :var assignments in ob-* for lisps and non-lisps (was: org-babel guile source block bug in handling multiple values) Ihor Radchenko
2023-03-10 10:39 ` Zelphir Kaltstahl
2023-03-11 9:58 ` Ihor Radchenko
2023-03-11 18:30 ` Zelphir Kaltstahl
2023-03-12 11:33 ` Ihor Radchenko
2023-03-19 13:50 ` [PATCH] lisp/ob-scheme.el Zelphir Kaltstahl
2023-03-22 10:43 ` Ihor Radchenko [this message]
2023-03-25 14:34 ` Zelphir Kaltstahl
2023-03-26 9:32 ` Ihor Radchenko
2023-04-25 12:28 ` Ihor Radchenko
2023-04-29 11:08 ` Zelphir Kaltstahl
2023-03-09 13:10 ` org-babel guile source block bug in handling multiple values Ihor Radchenko
2023-03-10 10:42 ` Zelphir Kaltstahl
2023-03-11 10:18 ` Ihor Radchenko
2023-06-02 13:11 ` Ihor Radchenko
2023-03-09 13:11 ` Ihor Radchenko
2023-03-09 14:21 ` Daniel Kraus
2023-03-10 11:57 ` Ihor Radchenko
2023-03-10 10:45 ` Zelphir Kaltstahl
2023-03-08 1:13 ` Zelphir Kaltstahl
2023-03-08 8:55 ` Ihor Radchenko
2023-03-07 15:44 ` Max Nikulin
2023-03-07 21:41 ` Rudolf Adamkovič
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87edphoyls.fsf@localhost \
--to=yantar92@posteo.net \
--cc=brubar.cs@gmail.com \
--cc=bzg@gnu.org \
--cc=emacs-orgmode@gnu.org \
--cc=zelphirkaltstahl@posteo.de \
/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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.