[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: calc-embedded-activate
From: |
Roger Mason |
Subject: |
Re: calc-embedded-activate |
Date: |
Wed, 14 Jan 2004 07:50:01 -0330 |
User-agent: |
Gnus/5.1002 (Gnus v5.10.2) Emacs/21.1 (gnu/linux) |
Hello,
Jay Belanger <belanger@truman.edu> writes:
> Roger Mason <rmason@esd.mun.ca> writes:
>
> ...
>> %Embed
>> % $f := 2$
>> % $g := 2$
>> % $foo := 5$
>> % $f + g => $
> ...
>> The key combination `C-u 1 M-# a' leads to the following
>> backtrace:
>>
>> Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil)
>
> It looks like a bug with calc-embed, which perhaps can be fixed by
> commenting out the lines
> (if (looking-at calc-embedded-open-formula)
> (goto-char (match-end 1)))
> from the definition of calc-do-embed-activate in calc-embed.el.
> (It works for me.)
>
( lines snipped )
Thanks for your response.
I discovered later that terminating the %Embed % $...$ group with
another %Embed cures the problem. I'm not sure if this is consistent
with your analysis or not. The terminating %Embed is not part of the
regex in calc-do-embedded-activate, indeed that regex pertains only to
the announcement of a group of formulae, so the `correct' behaviour could
be fortuitous. Commenting out the ofending lines is cleaner, I'll try
it here and report back.
Having got `M-# a' to work, albeit by trial and error, I have been
trying to update all the fomulae in the buffer using `C-u 1 M-# u'.
This command fails silently: nothing happens and there is no error
signalled. `M-u' works as described in the manual, so I assume the
bug (if it is a bug and not my stupidity) is in the code that steps
through the buffer finding active formulae. I presume the best way to
proceed is to improve my aquaintance with the lisp debugger, but if
anyone has any suggestions I'd be grateful to receive them.
Thanks,
Roger Mason