OLD | NEW |
(Empty) | |
| 1 Prism.languages.tcl = { |
| 2 'comment': { |
| 3 pattern: /(^|[^\\])#.*/, |
| 4 lookbehind: true |
| 5 }, |
| 6 'string': /"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*"/, |
| 7 'variable': [ |
| 8 { |
| 9 pattern: /(\$)(?:::)?(?:[a-zA-Z0-9]+::)*[a-zA-Z0-9_]+/, |
| 10 lookbehind: true |
| 11 }, |
| 12 { |
| 13 pattern: /(\$){[^}]+}/, |
| 14 lookbehind: true |
| 15 }, |
| 16 { |
| 17 pattern: /(^\s*set[ \t]+)(?:::)?(?:[a-zA-Z0-9]+::)*[a-zA
-Z0-9_]+/m, |
| 18 lookbehind: true |
| 19 } |
| 20 ], |
| 21 'function': { |
| 22 pattern: /(^\s*proc[ \t]+)[^\s]+/m, |
| 23 lookbehind: true |
| 24 }, |
| 25 'builtin': [ |
| 26 { |
| 27 pattern: /(^\s*)(?:proc|return|class|error|eval|exit|for
|foreach|if|switch|while|break|continue)\b/m, |
| 28 lookbehind: true |
| 29 }, |
| 30 /\b(elseif|else)\b/ |
| 31 ], |
| 32 'scope': { |
| 33 pattern: /(^\s*)(global|upvar|variable)\b/m, |
| 34 lookbehind: true, |
| 35 alias: 'constant' |
| 36 }, |
| 37 'keyword': { |
| 38 pattern: /(^\s*|\[)(after|append|apply|array|auto_(?:execok|impo
rt|load|mkindex|qualify|reset)|automkindex_old|bgerror|binary|catch|cd|chan|cloc
k|close|concat|dde|dict|encoding|eof|exec|expr|fblocked|fconfigure|fcopy|file(?:
event|name)?|flush|gets|glob|history|http|incr|info|interp|join|lappend|lassign|
lindex|linsert|list|llength|load|lrange|lrepeat|lreplace|lreverse|lsearch|lset|l
sort|math(?:func|op)|memory|msgcat|namespace|open|package|parray|pid|pkg_mkIndex
|platform|puts|pwd|re_syntax|read|refchan|regexp|registry|regsub|rename|Safe_Bas
e|scan|seek|set|socket|source|split|string|subst|Tcl|tcl(?:_endOfWord|_findLibra
ry|startOf(?:Next|Previous)Word|wordBreak(?:After|Before)|test|vars)|tell|time|t
m|trace|unknown|unload|unset|update|uplevel|vwait)\b/m, |
| 39 lookbehind: true |
| 40 }, |
| 41 'operator': /!=?|\*\*?|==|&&?|\|\|?|<[=<]?|>[=>]?|[-+~\/%?^]|\b(?:eq|ne|
in|ni)\b/, |
| 42 'punctuation': /[{}()\[\]]/ |
| 43 }; |
OLD | NEW |