help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: reloading mode


From: Kai Grossjohann
Subject: Re: reloading mode
Date: Sat, 27 Nov 2004 21:14:21 +0100
User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux)

Daniel Pittman <daniel@rimspace.net> writes:

> On 23 Nov 2004, Alex Polite wrote:
>> I'm altering a mode (transcript.el). Restarting emacs after every edit
>> to the mode file is very tedious. What's the right way of doing it?
>
> You can put your cursor at or after the closing bracket in the
> expression and hit 'C-M-x' to run `eval-defun' and, as such, execute the
> changed code.

C-M-x is used *inside* the expression to evaluate.  C-x C-e is used
after the closing parenthesis.

One other difference is that C-M-x only evaluates top-level
expressions, but C-x C-e can be used inside expressions, too.

C-M-x handles defvar specially, I think that C-x C-e does not.
(The special handling means that changing the value in a defvar and
then doing C-M-x in it changes the value of the variable in Emacs,
although the standard definition of defvar does not change the
variable's value, if it already has one.)

Kai






reply via email to

[Prev in Thread] Current Thread [Next in Thread]