tags 6411 + patch thanks On Wed, 21 Aug 2019 20:08:29 +0300 Eli Zaretskii wrote: > Sorry, but I happen to think the proposed implementation is somewhat > inelegant: > > . what's with the "(interactive (list nil))" part? > . why not just make ispell-comments-and-strings accept a prefix > argument to modify its behavior? > . alternatively, why not make ispell-comments-and-strings be > sensitive to the active region? > . as yet another alternative, make the new ispell-comment-or-string > narrow to the comment/string at point and then call > ispell-comments-and-strings with no code changes whatsoever; then > make the new command be sensitive to active region, and fall back > on the string/comment at point if no active region On Wed, 21 Aug 2019 22:57:21 +0200 Stefan Kangas wrote: > Let's hope someone picks up the ball and provides us with a revised or > new patch. If Lennart Borgman doesn't feel up to it after all these > years, maybe someone else? Here's my take on it. I didn't go the narrowing route, as I think it is useful to have full context during spelling corrections (recursive edit etc.). I also didn't see an obvious way to reuse one function/command from the other, as in order to get bounds of a comment/string, we have to parse the (part of the) buffer, by which point we can just pass the bounds straight to `ispell-region'. I did update `ispell-comments-and-strings' to honour active region and take optional bounds, anyway, as it seems useful in itself. One other possibility I see would be to merge the two commands and condition the "at-point" functionality on a prefix argument, but then the name ('ispell-comments-and-strings') would probably have to be changed, anyway (and to what?), and perhaps the command would already become too much of a kitchen sink. -- Štěpán