[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: movement bindings in c-mode
From: |
Alan Mackenzie |
Subject: |
Re: movement bindings in c-mode |
Date: |
Fri, 27 Jun 2008 21:49:27 +0000 |
User-agent: |
Mutt/1.5.9i |
Hi, David!
On Mon, Jun 23, 2008 at 08:36:14PM +0200, David Hansen wrote:
> On Mon, 23 Jun 2008 17:05:53 +0000 Alan Mackenzie wrote:
> > Just one small point, though. The doc-string for
> > beginning-of-defun-function recommends putting point at the { rather
> > than the function header. I think this is unright. Stefan?
> Actually I would prefer to have it in front of the `{'. If you just
> want to read something around the b-o-d it doesn't matter.
It matters, I think, when you do C-x n d. Then you can see what
function you're within.
> But if you want to edit something it's far more likely that it is within
> the body, e.g. adding a variable, than the header.
I'd conjecture that any line within a defun is as likely to be edited as
any other. That you've got an extra 3 or 4 lines to move forward to
that point doesn't seem that critical.
But I think the critical reason is that the command is called
beginning-of-defun, not beginning-of-defun-block, and commands should do
what they say. It would be possible to modify b-o-d so that a bare
prefix (C-u) would go to the block rather than the header. But I don't
think it would be worth the extra complication.
> David
--
Alan Mackenzie (Nuremberg, Germany).