From: Aaron Ecay <aaronecay@gmail.com>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>,
Andreas Leha <andreas.leha@med.uni-goettingen.de>
Cc: emacs-orgmode@gnu.org
Subject: Re: problems with export and :cache
Date: Thu, 29 Oct 2015 15:14:23 +0000 [thread overview]
Message-ID: <87io5pyaeo.fsf@gmail.com> (raw)
In-Reply-To: <871tcdpxeq.fsf@nicolasgoaziou.fr>
Hi Nicolas,
2015ko urriak 29an, Nicolas Goaziou-ek idatzi zuen:
>
> Hello,
>
> Aaron Ecay <aaronecay@gmail.com> writes:
>
>> The simple patch attached to this message fixes a bug that my testing
>> indicated was responsible for erroneous re-evaluations at least some
>> of the time.
>
> Thank you. A minor comment follows.
>
>> (cons :result-type (cond ((member "output" result-params) 'output)
>> ((member "value" result-params) 'value)
>> (t 'value))))
>> - (org-babel-get-header params :var 'other))))
>> + (loop for item in params
>> + unless (memq (car item) '(:colname-names
>> + :rowname-names
>> + :result-params
>> + :result-type
>> + :var))
>> + collect item))))
>
> Using `loop' here is, IMO, over-doing it. You can use instead, e.g.,
>
> (org-remove-if
> (lambda (item)
> (memq (car item)
> '(:colname-names :rowname-names :result-params :result-type :var)))
> params)
OK. I’ll push this to maint later today.
>
> Another option is to extend `org-babel-get-header' to accept a list of
> keys instead of a single key.
I’d like to remove this function, actually. I hate the org functions
that do X most of the time, but the opposite of X when you pass them
an optional argument (in this case the third arg ‘other’). Almost
all (a couple dozen in total) of the calls to o-b-get-header are in
the context (mapcar #'cdr (org-babel-get-header params :var)). I’d
like to introduce a function org-babel--get-var-values to cover these
cases, and replace the remaining 2 calls in the codebase (which both
extract :column-names) with assq (since :column-names should appear
maximally once, unlike :var). The sole use of the evil 'other arg is
refactored away by my patch.
Thoughts?
--
Aaron Ecay
next prev parent reply other threads:[~2015-10-29 15:14 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-28 21:37 problems with export and :cache Andreas Leha
2015-10-28 21:45 ` Andreas Leha
2015-10-29 13:34 ` Aaron Ecay
2015-10-29 14:22 ` Nicolas Goaziou
2015-10-29 15:14 ` Aaron Ecay [this message]
2015-10-29 16:42 ` Nicolas Goaziou
2015-10-29 17:05 ` Aaron Ecay
2015-10-29 17:16 ` Nicolas Goaziou
2015-10-29 19:11 ` Aaron Ecay
2015-10-30 23:40 ` Andreas Leha
2015-11-07 16:37 ` Achim Gratz
2015-11-07 20:33 ` Aaron Ecay
2015-11-07 22:43 ` Achim Gratz
2015-10-29 14:58 ` Andreas Leha
2015-10-29 15:17 ` Aaron Ecay
2015-10-29 16:51 ` Nicolas Goaziou
2015-10-29 19:05 ` Aaron Ecay
2015-10-29 20:32 ` Thomas S. Dye
2015-10-29 23:01 ` Andreas Leha
2015-11-01 22:56 ` Nicolas Goaziou
2015-11-04 12:01 ` Aaron Ecay
2015-11-04 22:41 ` Nicolas Goaziou
2015-11-05 14:51 ` Aaron Ecay
2015-11-05 14:55 ` Nicolas Goaziou
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.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87io5pyaeo.fsf@gmail.com \
--to=aaronecay@gmail.com \
--cc=andreas.leha@med.uni-goettingen.de \
--cc=emacs-orgmode@gnu.org \
--cc=mail@nicolasgoaziou.fr \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
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).