emacs-devel
[Top][All Lists]
Advanced

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

Re: comment-dwim on blank lines


From: Stefan Monnier
Subject: Re: comment-dwim on blank lines
Date: Thu, 01 Nov 2007 21:14:00 -0400
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/23.0.50 (gnu/linux)

> If comment-dwim is called on a non-blank line, it calls comment-indent
> to do the work of either inserting or indenting a comment. On a blank
> line, it does the work of inserting a new comment itself. Is there a
> reason for this difference in behaviour?

> It means that there isn't really any way for modes to customize what
> comment-dwim does on blank lines, other than by abusing
> indent-line-function. In particular, comment-insert-comment-function
> does not get called, which seems to contradict its doc-string.

It's clearly an oversight.  comment-insert-comment-function was added due to
a specific need and whoever implemented didn't look at other related cases.
Feel free to fix it.


        Stefan




reply via email to

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