Hello, I'm working on enhancing a noweb syntax file that I found, which is a tool for doing literate programming. That means that I have to include a lot of syntax files inside the noweb one to get highlighting for whatever code is being used inside the literate file.
Most languages I've tried work just fine: C, Java, Haskell, OCaml. But Perl is giving me some troubles. The issue is that when I start a syntax region that contains the included Perl syntax, the Perl starts off immediately highlighting a perlFunctionName, and it never ends; so the entirety of my Perl code is highlighted as such. I isolated it to a specific line in the Perl syntax, although I don't really understand the purpose of it so I can't quite fix it. But removing this line does eliminate the problem: (line 368) syn match perlFunctionName "\h[[:alnum:]_:]*" contained As you can see, this will match pretty much anything alphabetic when it's contained in a region as it is in my noweb syntax file. Here's a simple example: (test.vim) syntax include @testPerl syntax/perl.vim syntax region testRegion start=/<<</ end=/>>>/ keepend contai...@testperl (test.txt - use syntax=test) <<< use warnings; asdfasdfasdf >>> In the above test.txt, the whole content between the angle brackets will be highlighted as a perlFunctionName (except the semicolon). Is there any way to work around this, or is it perhaps a flaw in the Perl syntax file? Best regards, -- Taylor Venable http://metasyntax.net/ --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
