emacs-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 1/2] Merge subword-mode and capitalized-words-mode


From: Stefan Monnier
Subject: Re: [PATCH 1/2] Merge subword-mode and capitalized-words-mode
Date: Tue, 07 Aug 2012 16:37:34 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux)

> subword-mode began life as part of cc-mode, but because it's
> generally useful, it was extracted and made a generic part of
> Emacs.  subword-mode uses command remapping to achive its subword
> motion, however, and this mechanism can't catch all kinds of word-
> based motion, resulting in inconsistency.

> capitalized-words-mode attempts to do what subword-mode does, but
> using a hook added to C core for the purpose.  This hook allows
> capitalizd-words-mode to change all kinds of word-based motion
> into subword motion.  Unfortunately, capitalized-words-mode used
> overly simplistic code that caused it to fail to properly move
> over words like "fooBarBAZ"; subword-mode handles these words
> properly.  capitalized-words-mode is also disadvantaged by
> a long and misleading name.

> This patch merges subword-mode and capitalized-words-mode by
> modifying subword-mode to use the core hook and marking
> capitalized-words-mode as an obsolete alias for subword-mode.

I like consolidation like that.  But now, I wonder about bugs that can
be introduced by the pervasive impact of capitalized-words-mode.

My guess is that most of the potential problems we might bump into will
be the result of bugs that can also be triggered without
capitalized-words-mode (i.e. they just get triggered more easily with
capitalized-words-mode).


        Stefan



reply via email to

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