* Problem with Emacs 21.3 pretest
@ 2002-05-27 19:42 Ehud Karni
2002-05-28 5:16 ` Richard Stallman
0 siblings, 1 reply; 8+ messages in thread
From: Ehud Karni @ 2002-05-27 19:42 UTC (permalink / raw)
Cc: emacs-devel
I have a strange problem with Emacs 21.3.
It works as expected on tty (emacs -nw) but fails on X and I can't
debug it because I don't get any real information.
Here is the command line and its output:
ehud@beta[pts/1]-~-1520% emacs-21.2.90.1 -q --no-site-file --debug-init
Attempt to modify read-only object
Exit 255 <---- this is reported by tcsh
The emacs-version is:
GNU Emacs 21.2.90.1 (i686-redhat-linux-gnu, X toolkit, Xaw3d scroll bars) of 2002-05-27 on beta
An important note: This is a dumped emacs which contains many elisp
packages (1122604 pure bytes used).
Ehud.
--
Ehud Karni Tel: +972-3-7966-561 /"\
Mivtach - Simon Fax: +972-3-7966-667 \ / ASCII Ribbon Campaign
Insurance agencies (USA) voice mail and X Against HTML Mail
http://www.mvs.co.il FAX: 1-815-5509341 / \
mailto:ehud@unix.simonwiesel.co.il Better Safe Than Sorry
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-27 19:42 Problem with Emacs 21.3 pretest Ehud Karni
@ 2002-05-28 5:16 ` Richard Stallman
2002-05-28 10:12 ` Ehud Karni
0 siblings, 1 reply; 8+ messages in thread
From: Richard Stallman @ 2002-05-28 5:16 UTC (permalink / raw)
Cc: eliz, emacs-devel
Here is the command line and its output:
ehud@beta[pts/1]-~-1520% emacs-21.2.90.1 -q --no-site-file --debug-init
Attempt to modify read-only object
Exit 255 <---- this is reported by tcsh
Please run it under GDB with a breakpoint at pure_write_error
and send the backtrace.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-28 5:16 ` Richard Stallman
@ 2002-05-28 10:12 ` Ehud Karni
2002-05-29 16:25 ` Richard Stallman
0 siblings, 1 reply; 8+ messages in thread
From: Ehud Karni @ 2002-05-28 10:12 UTC (permalink / raw)
Cc: emacs-devel
On Mon, 27 May 2002 23:16:19 -0600 (MDT), Richard Stallman <rms@gnu.org> wrote:
>
> ehud@beta[pts/1]-~-1520% emacs-21.2.90.1 -q --no-site-file --debug-init
> Attempt to modify read-only object
>
> Please run it under GDB with a breakpoint at pure_write_error
> and send the backtrace.
OK. The trace allowed me to solve this error.
(gdb) break pure_write_error
Breakpoint 1 at 0x8113282
(gdb) run
Starting program: /usr/local/bin/emacs-21.3
Breakpoint 1, 0x08113282 in pure_write_error ()
(gdb) where
#0 0x08113282 in pure_write_error ()
#1 0x080d7b26 in parse_menu_item ()
#2 0x08071b2f in single_menu_item ()
#3 0x08071a44 in single_keymap_panes ()
#4 0x08071c1e in single_menu_item ()
#5 0x08071a44 in single_keymap_panes ()
#6 0x08072d54 in single_submenu ()
The reason was these definitions (note the `defconst' of the keymap list):
(defconst EK-menu-mark-3
'(keymap "EK Marks whole ops"
(copy-mk menu-item " copy marked " copy-marked :keys "F3" )
(move-mk menu-item " move marked " move-marked :keys "S-F3" )
(overlay menu-item "overlay marked" overlay-marked :keys "Ctrl-S-F9" :enable (= type-mark-set 4))
(dlt-mrk menu-item "delete marked" delete-marked :keys "Ctrl-F9" )
(-1 "--")
(fill-mk menu-item "fill with char" fill-marked :keys "Ctrl-F8" )
(shift-r menu-item "shift right marked" shift-marked :keys "Alt-S-+" :enable (/= type-mark-set 2))
(shift-l menu-item "shift left marked " shift-marked-left :keys "Alt-S--" :enable (/= type-mark-set 2))
(reflowm menu-item "reformat marked" reflow-marked :keys "C-x R" )
)
"EK marks sub 3 - whole ops")
(defconst EK-ops-menu
(list 'keymap "EK ops"
(list 'sav 'menu-item "saves/grep/tabs/shell" EK-menu-save)
(list 'lng 'menu-item "Languge/direction/mode" EK-menu-lang)
'(-1 "--")
'(-2 "--")
(list 'sm1 'menu-item "EK Marks un/marking" EK-menu-mark-1)
(list 'sm2 'menu-item "EK Marks push/pop" EK-menu-mark-2)
'(-3 menu-item "--" nil :visible (mark-exist-chk))
(list 'sm3 'menu-item "Whole marked area ops" EK-menu-mark-3 ':visible '(mark-exist-chk))
(list 'sm4 'menu-item "Translate in marked" EK-menu-mark-4 ':visible '(mark-exist-chk))
(list 'sm5 'menu-item "Marked area lines ops" EK-menu-mark-5 ':visible '(mark-exist-chk))
(list 'sm6 'menu-item "marked area as input" EK-menu-mark-6 ':visible '(mark-exist-chk))
'(-4 "--")
'(compute menu-item "compute expression" compute :keys "Alt-C" )
'(cmp-wnd menu-item "compare next window" compare-windows )
'(fix-col menu-item "Fixed column movment" col-move-fix-toggle :keys "Alt-X" :button (:toggle . (not position-col-var)))
)
"EK marks menu")
(define-key global-map [menu-bar EK_ops] (list 'menu-item "EK ops" EK-ops-menu))
When I changed all the `defconst' to `defvar' this problem disappeared.
I still wonder why does `parse_menu_item' change the values of my vars (constants).
I have other problems, I'm working on it.
Ehud.
--
Ehud Karni Tel: +972-3-7966-561 /"\
Mivtach - Simon Fax: +972-3-7966-667 \ / ASCII Ribbon Campaign
Insurance agencies (USA) voice mail and X Against HTML Mail
http://www.mvs.co.il FAX: 1-815-5509341 / \
mailto:ehud@unix.simonwiesel.co.il Better Safe Than Sorry
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-28 10:12 ` Ehud Karni
@ 2002-05-29 16:25 ` Richard Stallman
2002-05-29 17:08 ` Stefan Monnier
0 siblings, 1 reply; 8+ messages in thread
From: Richard Stallman @ 2002-05-29 16:25 UTC (permalink / raw)
Cc: emacs-devel
When I changed all the `defconst' to `defvar' this problem disappeared.
I still wonder why does `parse_menu_item' change the values of my vars (constants).
The change is due to caching the keyboard equivalents of these menu
items. That is done so menu redisplay can be fast.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-29 16:25 ` Richard Stallman
@ 2002-05-29 17:08 ` Stefan Monnier
2002-05-29 22:12 ` Miles Bader
2002-05-31 7:04 ` Richard Stallman
0 siblings, 2 replies; 8+ messages in thread
From: Stefan Monnier @ 2002-05-29 17:08 UTC (permalink / raw)
Cc: ehud, emacs-devel
> When I changed all the `defconst' to `defvar' this problem disappeared.
> I still wonder why does `parse_menu_item' change the values of my vars (constants).
>
> The change is due to caching the keyboard equivalents of these menu
> items. That is done so menu redisplay can be fast.
Note that I'm less and less sure that this caching is still important.
I have turned it off here (or rather I have changed the code to always
refresh the cache) and it's not noticeably slower (on my 266Mhz PII).
The worst case is with X-Symbol which has an enormous keymap (because
of two input methods implemented as keymaps: one in a menu and another
bound to C-=) where the menu takes about 1s to come up.
Stefan
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-29 17:08 ` Stefan Monnier
@ 2002-05-29 22:12 ` Miles Bader
2002-05-31 7:05 ` Richard Stallman
2002-05-31 7:04 ` Richard Stallman
1 sibling, 1 reply; 8+ messages in thread
From: Miles Bader @ 2002-05-29 22:12 UTC (permalink / raw)
Cc: Richard Stallman, ehud, emacs-devel
"Stefan Monnier" <monnier+gnu/emacs@RUM.cs.yale.edu> writes:
> Note that I'm less and less sure that this caching is still important.
> I have turned it off here (or rather I have changed the code to always
> refresh the cache) and it's not noticeably slower (on my 266Mhz PII).
I agree that the `menu-item munging' is bad, it often seems to be the
cause of wierd `bugs'.
Couldn't we just use a (weak) hash table to do the caching, anyway?
Then it could still cache, but it wouldn't munge the input.
-Miles
--
Saa, shall we dance? (from a dance-class advertisement)
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-29 17:08 ` Stefan Monnier
2002-05-29 22:12 ` Miles Bader
@ 2002-05-31 7:04 ` Richard Stallman
1 sibling, 0 replies; 8+ messages in thread
From: Richard Stallman @ 2002-05-31 7:04 UTC (permalink / raw)
Cc: ehud, emacs-devel
The worst case is with X-Symbol which has an enormous keymap (because
of two input methods implemented as keymaps: one in a menu and another
bound to C-=) where the menu takes about 1s to come up.
I would say that is serious. Users expect menus to appear very quickly.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: Problem with Emacs 21.3 pretest
2002-05-29 22:12 ` Miles Bader
@ 2002-05-31 7:05 ` Richard Stallman
0 siblings, 0 replies; 8+ messages in thread
From: Richard Stallman @ 2002-05-31 7:05 UTC (permalink / raw)
Cc: monnier+gnu/emacs, ehud, emacs-devel
Couldn't we just use a (weak) hash table to do the caching, anyway?
That idea seems worth trying. (We did not have weak hash tables back
then.) If it is fast enough (and I expect it is), it would be a big
increase in clarity and reliability. Would you like to try
implementing it?
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2002-05-31 7:05 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-05-27 19:42 Problem with Emacs 21.3 pretest Ehud Karni
2002-05-28 5:16 ` Richard Stallman
2002-05-28 10:12 ` Ehud Karni
2002-05-29 16:25 ` Richard Stallman
2002-05-29 17:08 ` Stefan Monnier
2002-05-29 22:12 ` Miles Bader
2002-05-31 7:05 ` Richard Stallman
2002-05-31 7:04 ` Richard Stallman
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.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).