Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 484610

Summary: app-editors/vim-core - faulty highlighting and folding for compound initializers in C syntax
Product: Gentoo Linux Reporter: Cedric Sodhi <manday>
Component: Current packagesAssignee: Vim Maintainers <vim>
Status: RESOLVED NEEDINFO    
Severity: normal CC: manday
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: C file with correct C99 syntax

Description Cedric Sodhi 2013-09-11 19:45:02 UTC
Created attachment 358490 [details]
C file with correct C99 syntax

Since other VIM users, using the upstream vim of version 7.4 with the according vanilla C syntax file (v 7.4.22 here) do not reproduce the issue, I have to assume it's Gentoo specific.

For one, compound intializers such as

myFuncTakingArray3OfInt( (int[]){1,2,3} )

are highlighted as errors (seemingly because the curly braces appear within round parenthesis).

Further, folding does not work correctly near such compound intializers. See the attached file where vim claims the block level dropped to 0 from l.6 to l.7.
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2013-09-13 13:22:22 UTC
Which version of app-editors/vim-core is that?
Comment 2 Cedric Sodhi 2013-09-14 06:36:07 UTC
(In reply to Jeroen Roovers from comment #1)
> Which version of app-editors/vim-core is that?

vim-core-7.4.22 as well.
Comment 3 Patrice Clement gentoo-dev 2017-10-25 07:34:06 UTC
(In reply to Cedric Sodhi from comment #0)
>
> Since other VIM users, using the upstream vim of version 7.4 with the
> according vanilla C syntax file (v 7.4.22 here) do not reproduce the issue,
> I have to assume it's Gentoo specific.
> 

Hi Cedric!

I have tried with upstream's C syntax and it doesn't work either (8.0.1188). Please reopen this bug with a link to the syntax file that works on your end and we will add it to our repo.

Thanks!