*** perl.vim	Sun Sep 21 10:37:54 2008
--- C:\Documents and Settings\fritzbt\vimfiles\syntax\perl.vim	Fri Sep 26 22:23:38 2008
***************
*** 1,7 ****
  " Vim syntax file
  " Language:	Perl
  " Maintainer:	Nick Hibma <nick@van-laarhoven.org>
! " Last Change:	2007 March 13
  " Location:	http://www.van-laarhoven.org/vim/syntax/perl.vim
  "
  " Please download most recent version first before mailing
--- 1,7 ----
  " Vim syntax file
  " Language:	Perl
  " Maintainer:	Nick Hibma <nick@van-laarhoven.org>
! " Last Change:	2008 September 26
  " Location:	http://www.van-laarhoven.org/vim/syntax/perl.vim
  "
  " Please download most recent version first before mailing
***************
*** 359,366 ****
  
  " Functions
  "       sub [name] [(prototype)] {
! "
! syn region perlFunction		start="\s*\<sub\>" end="[;{]"he=e-1 contains=perlStatementSub,perlFunctionPrototype,perlFunctionPRef,perlFunctionName,perlComment
  syn keyword perlStatementSub	sub contained
  
  syn match  perlFunctionPrototype	"([^)]*)" contained
--- 359,365 ----
  
  " Functions
  "       sub [name] [(prototype)] {
! syn region perlFunction		start="\<sub\>" end="[;{]"he=e-1 contains=perlStatementSub,perlFunctionPrototype,perlFunctionPRef,perlFunctionName,perlComment
  syn keyword perlStatementSub	sub contained
  
  syn match  perlFunctionPrototype	"([^)]*)" contained
***************
*** 394,412 ****
  
  "
  " Folding
- 
  if exists("perl_fold")
    if !exists("perl_nofold_packages")
!     syn region perlPackageFold start="^package \S\+;\s*\(#.*\)\=$" end="^1;\s*\(#.*\)\=$" end="\n\+package"me=s-1 transparent fold keepend
    endif
    if !exists("perl_nofold_subs")
!     syn region perlSubFold     start="^\z(\s*\)\<sub\>.*[^};]$" end="^\z1}\s*\(#.*\)\=$" transparent fold keepend
!     syn region perlSubFold start="^\z(\s*\)\<\(BEGIN\|END\|CHECK\|INIT\)\>.*[^};]$" end="^\z1}\s*$" transparent fold keepend
    endif
  
    if exists("perl_fold_blocks")
!     syn region perlBlockFold start="^\z(\s*\)\(if\|elsif\|unless\|for\|while\|until\)\s*(.*)\(\s*{\)\=\s*\(#.*\)\=$" start="^\z(\s*\)foreach\s*\(\(my\|our\)\=\s*\S\+\s*\)\=(.*)\(\s*{\)\=\s*\(#.*\)\=$" end="^\z1}\s*;\=\(#.*\)\=$" transparent fold keepend
!     syn region perlBlockFold start="^\z(\s*\)\(do\|else\)\(\s*{\)\=\s*\(#.*\)\=$" end="^\z1}\s*while" end="^\z1}\s*;\=\(#.*\)\=$" transparent fold keepend
    endif
  
    setlocal foldmethod=syntax
--- 393,410 ----
  
  "
  " Folding
  if exists("perl_fold")
    if !exists("perl_nofold_packages")
!     syn region perlPackageFold start="^package \S\+;\s*\(#.*\)\=$" end="^1;\s*\(#.*\)\=$" end="\n\+package"me=s-1 transparent fold keepend extend
    endif
    if !exists("perl_nofold_subs")
!     syn region perlSubFold     start="\<sub\>.*[^};]$" end="}" transparent fold keepend extend
!     syn region perlSubFold start="\<\(BEGIN\|END\|CHECK\|INIT\)\>.*[^};]$" end="}" transparent fold keepend extend
    endif
  
    if exists("perl_fold_blocks")
!     syn region perlBlockFold start="\%(if\|elsif\|unless\|for\|while\|until\)\s*(.*)\_s*\%(#.*\n\_s*\)*{" start="foreach\s*\(\(my\|our\)\=\s*\S\+\s*\)\=(.*)\(\s*{\)\=\s*\(#.*\)\=$" end="}\s*;\=\(#.*\)\=$" transparent fold keepend extend
!     syn region perlBlockFold start="\%(do\|else\)\_s*\%(#.*\n\_s*\)*{" end="}" transparent fold keepend extend
    endif
  
    setlocal foldmethod=syntax
