emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Eric Schulte" <schulte.eric@gmail.com>
To: Dan Davison <dandavison7@gmail.com>
Cc: Chris Malone <chris.m.malone@gmail.com>,
	emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Re: Two questions about using a =#+begin_src emacs-lisp= block
Date: Mon, 21 Feb 2011 15:34:42 -0700	[thread overview]
Message-ID: <8739nh2ezn.fsf@gmail.com> (raw)
In-Reply-To: m162sdrpyg.fsf@c-76-126-254-216.hsd1.ca.comcast.net

[...]
>>
>> This is due to the fact that during export Org-mode copies the entire
>> buffer contents into a new export buffer (which is not associated with
>> any file, hence `buffer-file-name' returning nothing).  This is done so
>> that the exporter can operate destructively on the file contents without
>> affecting the original buffer.
>
> Ideally this should be an implementation detail that is completely
> hidden from the user. So I'd say that the fact that execution on export
> does not behave like interactive execution is a bug. Should we consider
> fixing this?
>

I'd push back on considering this a bug.

Babel currently makes no guarantees about the location in which
evaluation takes place (other than the :dir header argument), and I
would consider it an implementation detail that evaluation of emacs-lisp
does sometimes take place inside the Org-mode buffer (this is not true,
nor could it be for any other language).  By contrast Babel *does*
guarantee that header arguments are resolved in the original Org-mode
buffer, a guarantee that we explicitly maintain during export despite
the Org-mode buffer shuffling.

Best -- Eric

      reply	other threads:[~2011-02-21 22:36 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-20 22:08 Two questions about using a =#+begin_src emacs-lisp= block Chris Malone
2011-02-21 17:17 ` Eric Schulte
2011-02-21 18:31   ` Chris Malone
2011-02-21 19:48     ` Eric Schulte
2011-02-22 15:06       ` Chris Malone
2011-02-22 16:54         ` Eric Schulte
2011-02-22 16:57         ` Chris Malone
2011-02-22 18:06           ` Eric Schulte
2011-02-22 18:23             ` chris.m.malone
2011-02-22 18:45             ` Achim Gratz
2011-02-21 22:19   ` Dan Davison
2011-02-21 22:34     ` Eric Schulte [this message]

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=8739nh2ezn.fsf@gmail.com \
    --to=schulte.eric@gmail.com \
    --cc=chris.m.malone@gmail.com \
    --cc=dandavison7@gmail.com \
    --cc=emacs-orgmode@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.
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).