UNPKG

558 BJavaScriptView Raw
1Prism.languages.hoon = {
2 'constant': /%(?:\.[ny]|[\w-]+)/,
3 'comment': {
4 pattern: /::.*/,
5 greedy: true
6 },
7 'class-name': [
8 {
9 pattern: /@(?:[A-Za-z0-9-]*[A-Za-z0-9])?/
10 },
11 /\*/
12 ],
13 'function': /(?:\+[-+] {2})?(?:[a-z](?:[a-z0-9-]*[a-z0-9])?)/,
14 'string': {
15 pattern: /"[^"]*"|'[^']*'/,
16 greedy: true
17 },
18 'keyword': /\.[\^\+\*=\?]|![><:\.=\?!]|=[>|:,\.\-\^<+;/~\*\?]|\?[>|:\.\-\^<\+&~=@!]|\|[\$_%:\.\-\^~\*=@\?]|\+[|\$\+\*]|:[_\-\^\+~\*]|%[_:\.\-\^\+~\*=]|\^[|:\.\-\+&~\*=\?]|\$[|_%:<>\-\^&~@=\?]|;[:<\+;\/~\*=]|~[>|\$_%<\+\/&=\?!]|--|==/
19};