Hi.

I'm not really sure where to submit this patch, but I noticed that it's not 
possible for a header to be recognised as Objective C++; I've included 
inline a patch for runtime/filetype.vim that reuses the g:c_syntax_for_h 
variable to choose between objc and objcpp for what I believe to be the 
overall correct behaviour.

I have also submitted this as issue #44 on the google code project, but I'm 
not sure that's the place either.
http://code.google.com/p/vim/issues/detail?id=44

-a

3235[tip] 095053029997 2011-12-29 21:46 -0500 austin
Making ObjC++ .h headers act like normal C .h headers.

diff -r a96cb758a8d7 -r 095053029997 runtime/filetype.vim
--- a/runtime/filetype.vim Fri Dec 23 14:56:28 2011 +0100
+++ b/runtime/filetype.vim Thu Dec 29 21:46:25 2011 -0500
@@ -367,7 +367,11 @@

func! s:FTheader()
if match(getline(1, min([line("$"), 200])), '^@\(interface\|end\|class\)') 
> -1
- setf objc
+ if exists("g:c_syntax_for_h")
+ setf objc
+ else
+ setf objcpp
+ endif
elseif exists("g:c_syntax_for_h")
setf c
elseif exists("g:ch_syntax_for_h")

-- 
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

Raspunde prin e-mail lui