cecamp (Vim Github Repository) wrote:
*Describe the bug*
Normally, a multi-line comment in C will show a new "*" at the correct
indentation every time a carriage return is entered. However, that is
not the case with the attached example file. Instead, extra (unwanted)
spaces are prepended prior to the asterisk. Removing a line or two
from the example file often shows no initial spacing.
(hopefully I've successfully attached cindent-prblm.c and bad.vimrc,
because although nominally attached I don't see a confirmation list)
*To Reproduce*
Detailed steps to reproduce the behavior:
1. vim -u bad.vimrc cindent-prblm.c
2. Go to bottom of file: G
3. Append to bottom of file: o
4. You'll see that, instead of beginning with " * ", the line begins
with a number of unwanted extra spaces: " * "
5. I will note that deleting a line in the comment area above
frequently changes the number of unwanted initial spaces,
sometimes yielding no initial spaces; ie. "* "
*Expected behavior*
It should start with " * " (or some number of spaces following the
asterisk).
You can see what it should start with by
1. vim -u bad.vimrc cindent-prblm.c
2. Go to 4th line: 4G
3. Append: o
*Environment (please complete the following information):*
* Vim version [e.g. 8.1.1234] (Or paste the result of |vim --version|.)
VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Apr 16 2021 16:08:47)
Included patches: 1-2772
Compiled by c...@sphinx.fios-router.home
<mailto:c...@sphinx.fios-router.home>
Huge version with GTK3 GUI. Features included (+) or not (-):
* OS: [e.g. Ubuntu 18.04, Windows 10 1809, macOS 10.14]
Scientific Linux release 7.9 (Nitrogen)
* Terminal: [e.g. GNOME Terminal, mintty, iTerm2, tmux, GNU screen]
(Use GUI if you use the GUI.)
gnome terminal 3.28.2
Well, that figures. Although I told the tracker to attach the two files,
apparently it didn't. So I'll attach them now on the vimdev mailing
list. Sorry about that...
Chip Campbell
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/9fa977ec-b92a-af50-c095-2f5bc412de42%40drchip.org.
/* e
* A
* D
* V
*
* T
* w
* Q
* o
*
* -
* E
* -
*
* â
* â®
* â¡
*
* â
* I
* á¶
* t
* c
* -
* A
* -
* α
* Ï
* n
*
* -
* Performance: {{{2
filetype indent on
set cino=>s,e0,n0,f0,{0,}4,^-1s,:0,=s,g0,h1s,p2,t0,+2,(2,)20,*30
set fo=nroql2