emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Andrea Rossetti <andrea.rossetti@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Babel evaluation of Calc block not working, bug in Calc?
Date: Mon, 29 Sep 2014 01:56:16 +0200	[thread overview]
Message-ID: <84ppefuwnz.fsf@gmail.com> (raw)
In-Reply-To: 8738bkb0fh.fsf@vsl28t2g.ww011

dieter@duenenhof-wilhelm.de (H. Dieter Wilhelm) writes:
> But now we are getting: byte-code: Symbol's function definition is void:
> v!
>
> #+BEGIN_SRC calc :var v=3
> v + 4
> #+END_SRC
>

Hello Dieter, I think I got it!

1) I see the same error message as you see, for variables with
name "v" or "var"

2) diagnosys: I see that Calc tries to avoid name collisions by
adding a "var-" prefix to variable names, and by removing it when
it needs to. (see code in functions "calc-read-var-name" and
"calc-var-name")

3) temporary workaround: try to change ":var v=3" into ":var var-v=3",
it works for me, does it work for you too?

4) proposed correction (untested, and makes sense only if workaround 
actually works): in ob-calc.el, function org-babel-execute:calc,
the invocation of "calc-store-into" could prepend 'var- to its argument

5) warning: if one applies correction 4), then workaround 3) doesn't
work anymore 

  Hope it helps and makes sense for you too, kindest regards.

 Andrea

  reply	other threads:[~2014-09-28 23:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-22  7:04 Babel evaluation of Calc block not working, bug in Calc? H. Dieter Wilhelm
2014-09-28 23:56 ` Andrea Rossetti [this message]
2014-09-29 17:51   ` Andrea Rossetti
2014-10-04 18:31     ` H. Dieter Wilhelm
2014-10-06 20:31       ` Andrea Rossetti
2014-10-07  6:21         ` H. Dieter Wilhelm

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=84ppefuwnz.fsf@gmail.com \
    --to=andrea.rossetti@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).