From: Chong Yidong <cyd@stupidchicken.com>
To: Alan Mackenzie <acm@muc.de>
Cc: Sean O'Rourke <sorourke@cs.ucsd.edu>,
David Hansen <david.hansen@gmx.net>, Dave Love <fx@gnu.org>,
emacs-devel@gnu.org
Subject: Re: narrow-to-defun and mark-defun now work properly for CC Mode.
Date: Wed, 11 Apr 2007 14:04:59 -0400 [thread overview]
Message-ID: <87lkgypz1w.fsf@stupidchicken.com> (raw)
In-Reply-To: <20070409123730.GD1065@muc.de> (Alan Mackenzie's message of "9 Apr 2007 13\:18\:04 +0200\, Mon\, 9 Apr 2007 13\:37\:30 +0100")
Alan Mackenzie <acm@muc.de> writes:
> I've patched .../lisp/progmodes/cc-{defs,langs,cmds,awk}.el in savannah
> (but not yet at SourceForge) so that these two commands work properly -
> up till now, they've enclosed the region between the braces; now they
> enclose the entire function, including the function header.
>
> The basic idea is to set \(beginning\|end\)-of-defun-function to the
> corresponding CC Mode functions. However, C-M-[ae] remain bound
> directly to these CC Mode functions to allow optimisation for large
> argument (factor ~10 in speed).
The trouble is that font-lock uses {beginning/end}-of-defun-function.
Because c-{beginning/end}-of-defun-function is slow (which is
apparently unavoidable due to syntactic complications), it makes
font-lock unacceptably slow (> 20 seconds for M-> in xdisp.c).
Having narrow-to-defun including the function header would be nice,
but if no solution to the slowness problem arises quickly, I think
this change should be postphoned to post-22.
next prev parent reply other threads:[~2007-04-11 18:04 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-04-09 11:18 narrow-to-defun and mark-defun now work properly for CC Mode Alan Mackenzie
2007-04-09 17:00 ` Eric Hanchrow
2007-04-11 0:29 ` Nick Roberts
2007-04-11 5:27 ` martin rudalics
2007-04-11 17:26 ` Chong Yidong
2007-04-11 17:53 ` Chong Yidong
2007-04-11 18:53 ` Eli Zaretskii
2007-04-11 19:49 ` Alan Mackenzie
2007-04-11 20:22 ` Alan Mackenzie
2007-04-11 21:53 ` Robert J. Chassell
2007-04-11 20:51 ` Chong Yidong
2007-04-11 21:02 ` Alan Mackenzie
2007-04-11 22:19 ` Nick Roberts
2007-04-12 18:45 ` Alan Mackenzie
2007-04-12 22:04 ` Nick Roberts
2007-04-12 17:43 ` Richard Matthew Stallman
2007-04-12 19:08 ` Stefan Monnier
2007-04-11 21:21 ` Kim F. Storm
2007-04-12 3:18 ` Eli Zaretskii
2007-04-12 3:51 ` Nick Roberts
2007-04-12 19:08 ` Eli Zaretskii
2007-04-11 19:51 ` Kim F. Storm
2007-04-11 21:27 ` Edward O'Connor
2007-04-11 19:46 ` Richard Matthew Stallman
2007-04-11 18:04 ` Chong Yidong [this message]
2007-04-11 23:04 ` Richard Matthew Stallman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lkgypz1w.fsf@stupidchicken.com \
--to=cyd@stupidchicken.com \
--cc=acm@muc.de \
--cc=david.hansen@gmx.net \
--cc=emacs-devel@gnu.org \
--cc=fx@gnu.org \
--cc=sorourke@cs.ucsd.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).