GNU bug report logs -
#40185
28.0.50; Emacs Calc selection of a sub-formula doesn't highlight it
Previous Next
Reported by: Narendra Joshi <narendraj9 <at> gmail.com>
Date: Sun, 22 Mar 2020 18:25:01 UTC
Severity: normal
Found in version 28.0.50
Done: Mattias EngdegÄrd <mattiase <at> acm.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
Your bug report
#40185: 28.0.50; Emacs Calc selection of a sub-formula doesn't highlight it
which was filed against the emacs package, has been closed.
The explanation is attached below, along with your original report.
If you require more details, please reply to 40185 <at> debbugs.gnu.org.
--
40185: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=40185
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
23 mars 2020 kl. 20.06 skrev Narendra Joshi <narendraj9 <at> gmail.com>:
> Can you please help me
> understand what exactly the issue was and how declaring the variable
> fixed it? I see that it is `defvar`ed in `calc-ext.el`.
'defvar' without an initial value is a declaration scoped to the surrounding lexical scope (or file, if at top level). It appears that calc.el does not require calc-ext, so that math-comp-selected was assumed to be lexical where it was bound in math-format-stack-value. This caused it to have the wrong number further down the call tree (in math-comp-to-string-flat, I think).
In Emacs 26 and earlier, calc.el used dynamic binding.
Thanks for verifying! Patch pushed to emacs-27.
[Message part 3 (message/rfc822, inline)]
+ Start Emacs Calc with `C-x * *`.
+ Enter the following formula with:
' (a + b)^3 / c d
+ Move point to be before "+" and use "j s" to select the
sub-formula "(a + b)".
+ This should have hidden the rest of the formula. But it does
not.
3
(a + b)
1* --------
c d
Selecting a Calc sub-formula doesn't highlight it. For example, in
the stack entry above, I have selected (a + b) but other parts of
the formula are still visible. All commands operate on the
selected formula and it is selected as evident from the '*' after
the number of the stack entry. It is not highlighted. This seems
to be working fine in Emacs 26. It's broken in the latest Emacs
versions: Emacs 27 and Emacs 28. I can confirm that it is not
happening because of any of my configuration because I tried the
same thing with `emacs -Q` and the result was the same.
Best,
--
Narendra Joshi
This bug report was last modified 5 years and 56 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.