1" Vim syntax file 2" Language: Coco/R 3" Maintainer: Ashish Shukla <[email protected]> 4" Last Change: 2007 Aug 10 5" Remark: Coco/R syntax partially implemented. 6" License: Vim license 7 8" quit when a syntax file was already loaded 9if exists("b:current_syntax") 10 finish 11endif 12 13syn keyword cocoKeywords ANY CHARACTERS COMMENTS COMPILER CONTEXT END FROM IF IGNORE IGNORECASE NESTED PRAGMAS PRODUCTIONS SYNC TO TOKENS WEAK 14syn match cocoUnilineComment #//.*$# 15syn match cocoIdentifier /[[:alpha:]][[:alnum:]]*/ 16syn region cocoMultilineComment start=#/[*]# end=#[*]/# 17syn region cocoString start=/"/ skip=/\\"\|\\\\/ end=/"/ 18syn region cocoCharacter start=/'/ skip=/\\'\|\\\\/ end=/'/ 19syn match cocoOperator /+\||\|\.\.\|-\|(\|)\|{\|}\|\[\|\]\|=\|<\|>/ 20syn region cocoProductionCode start=/([.]/ end=/[.])/ 21syn match cocoPragma /[$][[:alnum:]]*/ 22 23hi def link cocoKeywords Keyword 24hi def link cocoUnilineComment Comment 25hi def link cocoMultilineComment Comment 26hi def link cocoIdentifier Identifier 27hi def link cocoString String 28hi def link cocoCharacter Character 29hi def link cocoOperator Operator 30hi def link cocoProductionCode Statement 31hi def link cocoPragma Special 32 33