On 2022-12-07,
rwmit...@gmail.com wrote:
> Reading runtime/changes.doc, I see using <Ctrl>U immediately after an indented
> comment line is created, undoes the auto comment and puts the cursor in the
> correct column for the next line. This is likely the correct solution for me.
>
> This is the relevant lines from the above document:
>
> *fo-r*
> r Automatically insert the current comment leader after hitting
> <Enter> in Insert mode.
> *fo-o*
> o Automatically insert the current comment leader after hitting 'o' or
> 'O' in Normal mode. In case comment is unwanted in a specific place
> use CTRL-U to quickly delete it. |i_CTRL-U|
> *fo-/*
> / When 'o' is included: do not insert the comment leader for a //
> comment after a statement, only when // is at the start of the line.
>
> The last 3 lines looks like exactly what I was initially asking for, but I
> don't understand how to make that happen.
That will add the option "letter" / to 'formatoptions'. See
apply only to C files. See