Changeset 24148
- Timestamp:
- 12/04/08 06:37:43 (5 weeks ago)
- Files:
-
- 1 modified
-
util/perl6.vim (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
util/perl6.vim
r24139 r24148 22 22 " * Overhaul Q// and its derivatives 23 23 " * Overhaul regexes 24 " * Highlight enum declarations correctly 25 " * :key should always be highlighted as a string, 26 " even if it's a known keyword 27 " * Highlight special numbers correctly (1_000, 0b0101, etc) 24 28 25 29 " For version 5.x: Clear all syntax items … … 47 51 syn keyword p6FlowControl take do when next last redo given return 48 52 syn keyword p6FlowControl default exit make 49 syn keyword p6TypeConstraint is but does trusts of returns53 syn keyword p6TypeConstraint is as but does trusts of returns also 50 54 syn keyword p6ClosureTrait BEGIN CHECK INIT START FIRST ENTER LEAVE KEEP 51 55 syn keyword p6ClosureTrait UNDO NEXT LAST PRE POST END 52 56 syn keyword p6Exception die fail try CATCH CONTROL warn 53 syn keyword p6Property prec key value irs ofs ors pos export deep also54 syn keyword p6Property rw signature returns ofparsed cached readonly57 syn keyword p6Property prec irs ofs ors pos export deep 58 syn keyword p6Property rw signature parsed cached readonly 55 59 syn keyword p6Property ref copy inline tighter looser equiv assoc 56 60 syn keyword p6Type Object Any Junction Whatever Capture Match … … 73 77 syn keyword p6Routine WHAT WHICH VAR eager hyper substr index rindex 74 78 syn keyword p6Routine grep map sort join split reduce min max reverse 75 syn keyword p6Routine truncate zip cat roundrobin classify first 79 syn keyword p6Routine truncate zip cat roundrobin classify first sum 76 80 syn keyword p6Routine keys values pairs defined delete exists elems 77 syn keyword p6Routine end kv arity assuming pick slice 78 syn keyword p6Routine any all none one wrap shape classify 79 syn keyword p6Routine callsame callwith nextsame nextwith 81 syn keyword p6Routine end kv arity assuming pick slice clone key 82 syn keyword p6Routine any all none one wrap shape classify value 83 syn keyword p6Routine callsame callwith nextsame nextwith ACCEPTS 80 84 syn keyword p6Routine pop push shift splice unshift floor ceiling 81 85 syn keyword p6Routine abs exp log log10 rand sign sqrt sin cos tan … … 98 102 syn keyword p6Routine nonce skip_rest eval_dies_ok eval_lives_ok 99 103 syn keyword p6Routine approx is_approx throws_ok version_lt 100 syn keyword p6Routine eval operator undef undefine sleep 104 syn keyword p6Routine eval operator undef undefine sleep from to 101 105 syn keyword p6Routine infix postfix prefix circumfix postcircumfix 102 106 syn keyword p6Operator x xx div mod also leg cmp … … 108 112 syn match p6Operator display "\%(&\|<\|>\|,\|\.\|;\)" 109 113 " these require whitespace on the left side 110 syn match p6Operator display "\%(^\|\s\)\@<=\%(xx=\|p5=>\ |\[\S\+\]\)"114 syn match p6Operator display "\%(^\|\s\)\@<=\%(xx=\|p5=>\)" 111 115 " these require whitespace on both sides 112 116 syn match p6Operator display "\%(^\|\s\)\@=\%(!eqv\|X\~X\|X\*X\)\@=\%(\s\|$\)" … … 122 126 syn match p6Shebang display "\%^#!.*" 123 127 syn match p6BlockLabel display "\%(^\s*\)\@<=\h\w*\s*:\s\@=" 124 syn match p6Variable display "[$@%][!.*^?]\?[[: graph:]_¢]\w*"128 syn match p6Variable display "[$@%][!.*^?]\?[[:alnum:]_¢]*" 125 129 126 130 " FIXME: This ugly hack will show up later on. Once again, don't try to fix it. 131 " E.g. this makes "@()" highlight properly in "@( bla() )" 127 132 syn region p6ParenExpression 128 133 \ start="\(<\s*\)\@<!(" … … 136 141 137 142 " contextualizers 143 syn match p6Contextualizer display "hash" 138 144 syn region p6ExplicitContext 139 145 \ matchgroup=p6Contextualizer … … 144 150 \ start="@@(" 145 151 \ end=")" 146 \ transparent147 152 \ contains=TOP 148 153 … … 160 165 \ add=p6Variable 161 166 \ add=p6InterpClosure 167 \ add=p6ExplicitContext 162 168 163 169 " "string" … … 288 294 \ contains=p6Variable 289 295 290 " : key<val>296 " :string 291 297 syn match p6LiteralString display ":\@<=\w\+" 292 298
