@canopycanopycanopy/b-ber-markdown-renderer 3.0.8-next.61 → 3.0.8-next.96
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +14 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +97 -77
- package/package.json +28 -28
- package/dist/highlightjs/highlight.js +0 -821
- package/dist/highlightjs/index.js +0 -191
- package/dist/highlightjs/languages/1c.js +0 -216
- package/dist/highlightjs/languages/abnf.js +0 -41
- package/dist/highlightjs/languages/accesslog.js +0 -41
- package/dist/highlightjs/languages/actionscript.js +0 -55
- package/dist/highlightjs/languages/ada.js +0 -157
- package/dist/highlightjs/languages/angelscript.js +0 -94
- package/dist/highlightjs/languages/apache.js +0 -44
- package/dist/highlightjs/languages/applescript.js +0 -44
- package/dist/highlightjs/languages/arcade.js +0 -108
- package/dist/highlightjs/languages/arduino.js +0 -13
- package/dist/highlightjs/languages/armasm.js +0 -91
- package/dist/highlightjs/languages/asciidoc.js +0 -174
- package/dist/highlightjs/languages/aspectj.js +0 -99
- package/dist/highlightjs/languages/autohotkey.js +0 -57
- package/dist/highlightjs/languages/autoit.js +0 -105
- package/dist/highlightjs/languages/avrasm.js +0 -42
- package/dist/highlightjs/languages/awk.js +0 -46
- package/dist/highlightjs/languages/axapta.js +0 -21
- package/dist/highlightjs/languages/bash.js +0 -64
- package/dist/highlightjs/languages/basic.js +0 -36
- package/dist/highlightjs/languages/bnf.js +0 -26
- package/dist/highlightjs/languages/brainfuck.js +0 -29
- package/dist/highlightjs/languages/cal.js +0 -65
- package/dist/highlightjs/languages/capnproto.js +0 -42
- package/dist/highlightjs/languages/ceylon.js +0 -60
- package/dist/highlightjs/languages/clean.js +0 -16
- package/dist/highlightjs/languages/clojure-repl.js +0 -14
- package/dist/highlightjs/languages/clojure.js +0 -69
- package/dist/highlightjs/languages/cmake.js +0 -26
- package/dist/highlightjs/languages/coffeescript.js +0 -139
- package/dist/highlightjs/languages/coq.js +0 -19
- package/dist/highlightjs/languages/cos.js +0 -111
- package/dist/highlightjs/languages/cpp.js +0 -144
- package/dist/highlightjs/languages/crmsh.js +0 -72
- package/dist/highlightjs/languages/crystal.js +0 -233
- package/dist/highlightjs/languages/cs.js +0 -162
- package/dist/highlightjs/languages/csp.js +0 -21
- package/dist/highlightjs/languages/css.js +0 -90
- package/dist/highlightjs/languages/d.js +0 -213
- package/dist/highlightjs/languages/dart.js +0 -84
- package/dist/highlightjs/languages/delphi.js +0 -60
- package/dist/highlightjs/languages/diff.js +0 -51
- package/dist/highlightjs/languages/django.js +0 -39
- package/dist/highlightjs/languages/dns.js +0 -28
- package/dist/highlightjs/languages/dockerfile.js +0 -17
- package/dist/highlightjs/languages/dos.js +0 -38
- package/dist/highlightjs/languages/dsconfig.js +0 -48
- package/dist/highlightjs/languages/dts.js +0 -92
- package/dist/highlightjs/languages/dust.js +0 -31
- package/dist/highlightjs/languages/ebnf.js +0 -24
- package/dist/highlightjs/languages/elixir.js +0 -85
- package/dist/highlightjs/languages/elm.js +0 -77
- package/dist/highlightjs/languages/erb.js +0 -14
- package/dist/highlightjs/languages/erlang-repl.js +0 -33
- package/dist/highlightjs/languages/erlang.js +0 -114
- package/dist/highlightjs/languages/excel.js +0 -44
- package/dist/highlightjs/languages/fix.js +0 -27
- package/dist/highlightjs/languages/flix.js +0 -33
- package/dist/highlightjs/languages/fortran.js +0 -38
- package/dist/highlightjs/languages/fsharp.js +0 -49
- package/dist/highlightjs/languages/gams.js +0 -100
- package/dist/highlightjs/languages/gauss.js +0 -147
- package/dist/highlightjs/languages/gcode.js +0 -57
- package/dist/highlightjs/languages/gherkin.js +0 -31
- package/dist/highlightjs/languages/glsl.js +0 -28
- package/dist/highlightjs/languages/gml.js +0 -17
- package/dist/highlightjs/languages/go.js +0 -44
- package/dist/highlightjs/languages/golo.js +0 -14
- package/dist/highlightjs/languages/gradle.js +0 -11
- package/dist/highlightjs/languages/groovy.js +0 -73
- package/dist/highlightjs/languages/haml.js +0 -79
- package/dist/highlightjs/languages/handlebars.js +0 -32
- package/dist/highlightjs/languages/haskell.js +0 -102
- package/dist/highlightjs/languages/haxe.js +0 -125
- package/dist/highlightjs/languages/hsp.js +0 -33
- package/dist/highlightjs/languages/htmlbars.js +0 -66
- package/dist/highlightjs/languages/http.js +0 -49
- package/dist/highlightjs/languages/hy.js +0 -73
- package/dist/highlightjs/languages/inform7.js +0 -52
- package/dist/highlightjs/languages/ini.js +0 -59
- package/dist/highlightjs/languages/irpf90.js +0 -43
- package/dist/highlightjs/languages/isbl.js +0 -526
- package/dist/highlightjs/languages/java.js +0 -75
- package/dist/highlightjs/languages/javascript.js +0 -149
- package/dist/highlightjs/languages/jboss-cli.js +0 -43
- package/dist/highlightjs/languages/json.js +0 -44
- package/dist/highlightjs/languages/julia-repl.js +0 -23
- package/dist/highlightjs/languages/julia.js +0 -125
- package/dist/highlightjs/languages/kotlin.js +0 -167
- package/dist/highlightjs/languages/lasso.js +0 -126
- package/dist/highlightjs/languages/ldif.js +0 -30
- package/dist/highlightjs/languages/leaf.js +0 -33
- package/dist/highlightjs/languages/less.js +0 -167
- package/dist/highlightjs/languages/lisp.js +0 -101
- package/dist/highlightjs/languages/livecodeserver.js +0 -66
- package/dist/highlightjs/languages/livescript.js +0 -138
- package/dist/highlightjs/languages/llvm.js +0 -54
- package/dist/highlightjs/languages/lsl.js +0 -55
- package/dist/highlightjs/languages/lua.js +0 -51
- package/dist/highlightjs/languages/makefile.js +0 -65
- package/dist/highlightjs/languages/markdown.js +0 -111
- package/dist/highlightjs/languages/mathematica.js +0 -22
- package/dist/highlightjs/languages/matlab.js +0 -70
- package/dist/highlightjs/languages/maxima.js +0 -44
- package/dist/highlightjs/languages/mel.js +0 -17
- package/dist/highlightjs/languages/mercury.js +0 -63
- package/dist/highlightjs/languages/mipsasm.js +0 -86
- package/dist/highlightjs/languages/mizar.js +0 -8
- package/dist/highlightjs/languages/mojolicious.js +0 -25
- package/dist/highlightjs/languages/monkey.js +0 -53
- package/dist/highlightjs/languages/moonscript.js +0 -108
- package/dist/highlightjs/languages/n1ql.js +0 -39
- package/dist/highlightjs/languages/nginx.js +0 -100
- package/dist/highlightjs/languages/nimrod.js +0 -46
- package/dist/highlightjs/languages/nix.js +0 -42
- package/dist/highlightjs/languages/nsis.js +0 -73
- package/dist/highlightjs/languages/objectivec.js +0 -59
- package/dist/highlightjs/languages/ocaml.js +0 -54
- package/dist/highlightjs/languages/openscad.js +0 -54
- package/dist/highlightjs/languages/oxygene.js +0 -49
- package/dist/highlightjs/languages/parser3.js +0 -31
- package/dist/highlightjs/languages/perl.js +0 -124
- package/dist/highlightjs/languages/pf.js +0 -32
- package/dist/highlightjs/languages/pgsql.js +0 -370
- package/dist/highlightjs/languages/php.js +0 -97
- package/dist/highlightjs/languages/plaintext.js +0 -7
- package/dist/highlightjs/languages/pony.js +0 -53
- package/dist/highlightjs/languages/powershell.js +0 -77
- package/dist/highlightjs/languages/processing.js +0 -15
- package/dist/highlightjs/languages/profile.js +0 -28
- package/dist/highlightjs/languages/prolog.js +0 -62
- package/dist/highlightjs/languages/properties.js +0 -62
- package/dist/highlightjs/languages/protobuf.js +0 -33
- package/dist/highlightjs/languages/puppet.js +0 -77
- package/dist/highlightjs/languages/purebasic.js +0 -51
- package/dist/highlightjs/languages/python.js +0 -110
- package/dist/highlightjs/languages/q.js +0 -16
- package/dist/highlightjs/languages/qml.js +0 -136
- package/dist/highlightjs/languages/r.js +0 -56
- package/dist/highlightjs/languages/reasonml.js +0 -214
- package/dist/highlightjs/languages/rib.js +0 -9
- package/dist/highlightjs/languages/roboconf.js +0 -51
- package/dist/highlightjs/languages/routeros.js +0 -183
- package/dist/highlightjs/languages/rsl.js +0 -23
- package/dist/highlightjs/languages/ruby.js +0 -181
- package/dist/highlightjs/languages/ruleslanguage.js +0 -21
- package/dist/highlightjs/languages/rust.js +0 -91
- package/dist/highlightjs/languages/sas.js +0 -49
- package/dist/highlightjs/languages/scala.js +0 -96
- package/dist/highlightjs/languages/scheme.js +0 -103
- package/dist/highlightjs/languages/scilab.js +0 -46
- package/dist/highlightjs/languages/scss.js +0 -76
- package/dist/highlightjs/languages/shell.js +0 -15
- package/dist/highlightjs/languages/smali.js +0 -48
- package/dist/highlightjs/languages/smalltalk.js +0 -41
- package/dist/highlightjs/languages/sml.js +0 -51
- package/dist/highlightjs/languages/sqf.js +0 -50
- package/dist/highlightjs/languages/sql.js +0 -40
- package/dist/highlightjs/languages/stan.js +0 -56
- package/dist/highlightjs/languages/stata.js +0 -28
- package/dist/highlightjs/languages/step21.js +0 -41
- package/dist/highlightjs/languages/stylus.js +0 -124
- package/dist/highlightjs/languages/subunit.js +0 -34
- package/dist/highlightjs/languages/swift.js +0 -90
- package/dist/highlightjs/languages/taggerscript.js +0 -35
- package/dist/highlightjs/languages/tap.js +0 -38
- package/dist/highlightjs/languages/tcl.js +0 -38
- package/dist/highlightjs/languages/tex.js +0 -56
- package/dist/highlightjs/languages/thrift.js +0 -29
- package/dist/highlightjs/languages/tp.js +0 -58
- package/dist/highlightjs/languages/twig.js +0 -55
- package/dist/highlightjs/languages/typescript.js +0 -120
- package/dist/highlightjs/languages/vala.js +0 -41
- package/dist/highlightjs/languages/vbnet.js +0 -53
- package/dist/highlightjs/languages/vbscript-html.js +0 -12
- package/dist/highlightjs/languages/vbscript.js +0 -21
- package/dist/highlightjs/languages/verilog.js +0 -44
- package/dist/highlightjs/languages/vhdl.js +0 -40
- package/dist/highlightjs/languages/vim.js +0 -53
- package/dist/highlightjs/languages/x86asm.js +0 -110
- package/dist/highlightjs/languages/xl.js +0 -55
- package/dist/highlightjs/languages/xml.js +0 -128
- package/dist/highlightjs/languages/xquery.js +0 -134
- package/dist/highlightjs/languages/yaml.js +0 -95
- package/dist/highlightjs/languages/zephir.js +0 -77
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports = function (hljs) {
|
|
4
|
-
var IDENT_RE = '[a-zA-Z_$][a-zA-Z0-9_$]*';
|
|
5
|
-
var IDENT_FUNC_RETURN_TYPE_RE = '([*]|[a-zA-Z_$][a-zA-Z0-9_$]*)';
|
|
6
|
-
var AS3_REST_ARG_MODE = {
|
|
7
|
-
className: 'rest_arg',
|
|
8
|
-
begin: '[.]{3}',
|
|
9
|
-
end: IDENT_RE,
|
|
10
|
-
relevance: 10
|
|
11
|
-
};
|
|
12
|
-
return {
|
|
13
|
-
aliases: ['as'],
|
|
14
|
-
keywords: {
|
|
15
|
-
keyword: 'as break case catch class const continue default delete do dynamic each ' + 'else extends final finally for function get if implements import in include ' + 'instanceof interface internal is namespace native new override package private ' + 'protected public return set static super switch this throw try typeof use var void ' + 'while with',
|
|
16
|
-
literal: 'true false null undefined'
|
|
17
|
-
},
|
|
18
|
-
contains: [hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE, hljs.C_LINE_COMMENT_MODE, hljs.C_BLOCK_COMMENT_MODE, hljs.C_NUMBER_MODE, {
|
|
19
|
-
className: 'class',
|
|
20
|
-
beginKeywords: 'package',
|
|
21
|
-
end: '{',
|
|
22
|
-
contains: [hljs.TITLE_MODE]
|
|
23
|
-
}, {
|
|
24
|
-
className: 'class',
|
|
25
|
-
beginKeywords: 'class interface',
|
|
26
|
-
end: '{',
|
|
27
|
-
excludeEnd: true,
|
|
28
|
-
contains: [{
|
|
29
|
-
beginKeywords: 'extends implements'
|
|
30
|
-
}, hljs.TITLE_MODE]
|
|
31
|
-
}, {
|
|
32
|
-
className: 'meta',
|
|
33
|
-
beginKeywords: 'import include',
|
|
34
|
-
end: ';',
|
|
35
|
-
keywords: {
|
|
36
|
-
'meta-keyword': 'import include'
|
|
37
|
-
}
|
|
38
|
-
}, {
|
|
39
|
-
className: 'function',
|
|
40
|
-
beginKeywords: 'function',
|
|
41
|
-
end: '[{;]',
|
|
42
|
-
excludeEnd: true,
|
|
43
|
-
illegal: '\\S',
|
|
44
|
-
contains: [hljs.TITLE_MODE, {
|
|
45
|
-
className: 'params',
|
|
46
|
-
begin: '\\(',
|
|
47
|
-
end: '\\)',
|
|
48
|
-
contains: [hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE, hljs.C_LINE_COMMENT_MODE, hljs.C_BLOCK_COMMENT_MODE, AS3_REST_ARG_MODE]
|
|
49
|
-
}, {
|
|
50
|
-
begin: ':\\s*' + IDENT_FUNC_RETURN_TYPE_RE
|
|
51
|
-
}]
|
|
52
|
-
}, hljs.METHOD_GUARD],
|
|
53
|
-
illegal: /#/
|
|
54
|
-
};
|
|
55
|
-
};
|
|
@@ -1,157 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports =
|
|
4
|
-
// We try to support full Ada2012
|
|
5
|
-
//
|
|
6
|
-
// We highlight all appearances of types, keywords, literals (string, char, number, bool)
|
|
7
|
-
// and titles (user defined function/procedure/package)
|
|
8
|
-
// CSS classes are set accordingly
|
|
9
|
-
//
|
|
10
|
-
// Languages causing problems for language detection:
|
|
11
|
-
// xml (broken by Foo : Bar type), elm (broken by Foo : Bar type), vbscript-html (broken by body keyword)
|
|
12
|
-
// sql (ada default.txt has a lot of sql keywords)
|
|
13
|
-
|
|
14
|
-
function (hljs) {
|
|
15
|
-
// Regular expression for Ada numeric literals.
|
|
16
|
-
// stolen form the VHDL highlighter
|
|
17
|
-
|
|
18
|
-
// Decimal literal:
|
|
19
|
-
var INTEGER_RE = '\\d(_|\\d)*';
|
|
20
|
-
var EXPONENT_RE = '[eE][-+]?' + INTEGER_RE;
|
|
21
|
-
var DECIMAL_LITERAL_RE = INTEGER_RE + '(\\.' + INTEGER_RE + ')?' + '(' + EXPONENT_RE + ')?';
|
|
22
|
-
|
|
23
|
-
// Based literal:
|
|
24
|
-
var BASED_INTEGER_RE = '\\w+';
|
|
25
|
-
var BASED_LITERAL_RE = INTEGER_RE + '#' + BASED_INTEGER_RE + '(\\.' + BASED_INTEGER_RE + ')?' + '#' + '(' + EXPONENT_RE + ')?';
|
|
26
|
-
var NUMBER_RE = '\\b(' + BASED_LITERAL_RE + '|' + DECIMAL_LITERAL_RE + ')';
|
|
27
|
-
|
|
28
|
-
// Identifier regex
|
|
29
|
-
var ID_REGEX = '[A-Za-z](_?[A-Za-z0-9.])*';
|
|
30
|
-
|
|
31
|
-
// bad chars, only allowed in literals
|
|
32
|
-
var BAD_CHARS = '[]{}%#\'\"';
|
|
33
|
-
|
|
34
|
-
// Ada doesn't have block comments, only line comments
|
|
35
|
-
var COMMENTS = hljs.COMMENT('--', '$');
|
|
36
|
-
|
|
37
|
-
// variable declarations of the form
|
|
38
|
-
// Foo : Bar := Baz;
|
|
39
|
-
// where only Bar will be highlighted
|
|
40
|
-
var VAR_DECLS = {
|
|
41
|
-
// TODO: These spaces are not required by the Ada syntax
|
|
42
|
-
// however, I have yet to see handwritten Ada code where
|
|
43
|
-
// someone does not put spaces around :
|
|
44
|
-
begin: '\\s+:\\s+',
|
|
45
|
-
end: '\\s*(:=|;|\\)|=>|$)',
|
|
46
|
-
// endsWithParent: true,
|
|
47
|
-
// returnBegin: true,
|
|
48
|
-
illegal: BAD_CHARS,
|
|
49
|
-
contains: [{
|
|
50
|
-
// workaround to avoid highlighting
|
|
51
|
-
// named loops and declare blocks
|
|
52
|
-
beginKeywords: 'loop for declare others',
|
|
53
|
-
endsParent: true
|
|
54
|
-
}, {
|
|
55
|
-
// properly highlight all modifiers
|
|
56
|
-
className: 'keyword',
|
|
57
|
-
beginKeywords: 'not null constant access function procedure in out aliased exception'
|
|
58
|
-
}, {
|
|
59
|
-
className: 'type',
|
|
60
|
-
begin: ID_REGEX,
|
|
61
|
-
endsParent: true,
|
|
62
|
-
relevance: 0
|
|
63
|
-
}]
|
|
64
|
-
};
|
|
65
|
-
return {
|
|
66
|
-
case_insensitive: true,
|
|
67
|
-
keywords: {
|
|
68
|
-
keyword: 'abort else new return abs elsif not reverse abstract end ' + 'accept entry select access exception of separate aliased exit or some ' + 'all others subtype and for out synchronized array function overriding ' + 'at tagged generic package task begin goto pragma terminate ' + 'body private then if procedure type case in protected constant interface ' + 'is raise use declare range delay limited record when delta loop rem while ' + 'digits renames with do mod requeue xor',
|
|
69
|
-
literal: 'True False'
|
|
70
|
-
},
|
|
71
|
-
contains: [COMMENTS,
|
|
72
|
-
// strings "foobar"
|
|
73
|
-
{
|
|
74
|
-
className: 'string',
|
|
75
|
-
begin: /"/,
|
|
76
|
-
end: /"/,
|
|
77
|
-
contains: [{
|
|
78
|
-
begin: /""/,
|
|
79
|
-
relevance: 0
|
|
80
|
-
}]
|
|
81
|
-
},
|
|
82
|
-
// characters ''
|
|
83
|
-
{
|
|
84
|
-
// character literals always contain one char
|
|
85
|
-
className: 'string',
|
|
86
|
-
begin: /'.'/
|
|
87
|
-
}, {
|
|
88
|
-
// number literals
|
|
89
|
-
className: 'number',
|
|
90
|
-
begin: NUMBER_RE,
|
|
91
|
-
relevance: 0
|
|
92
|
-
}, {
|
|
93
|
-
// Attributes
|
|
94
|
-
className: 'symbol',
|
|
95
|
-
begin: "'" + ID_REGEX
|
|
96
|
-
}, {
|
|
97
|
-
// package definition, maybe inside generic
|
|
98
|
-
className: 'title',
|
|
99
|
-
begin: '(\\bwith\\s+)?(\\bprivate\\s+)?\\bpackage\\s+(\\bbody\\s+)?',
|
|
100
|
-
end: '(is|$)',
|
|
101
|
-
keywords: 'package body',
|
|
102
|
-
excludeBegin: true,
|
|
103
|
-
excludeEnd: true,
|
|
104
|
-
illegal: BAD_CHARS
|
|
105
|
-
}, {
|
|
106
|
-
// function/procedure declaration/definition
|
|
107
|
-
// maybe inside generic
|
|
108
|
-
begin: '(\\b(with|overriding)\\s+)?\\b(function|procedure)\\s+',
|
|
109
|
-
end: '(\\bis|\\bwith|\\brenames|\\)\\s*;)',
|
|
110
|
-
keywords: 'overriding function procedure with is renames return',
|
|
111
|
-
// we need to re-match the 'function' keyword, so that
|
|
112
|
-
// the title mode below matches only exactly once
|
|
113
|
-
returnBegin: true,
|
|
114
|
-
contains: [COMMENTS, {
|
|
115
|
-
// name of the function/procedure
|
|
116
|
-
className: 'title',
|
|
117
|
-
begin: '(\\bwith\\s+)?\\b(function|procedure)\\s+',
|
|
118
|
-
end: '(\\(|\\s+|$)',
|
|
119
|
-
excludeBegin: true,
|
|
120
|
-
excludeEnd: true,
|
|
121
|
-
illegal: BAD_CHARS
|
|
122
|
-
},
|
|
123
|
-
// 'self'
|
|
124
|
-
// // parameter types
|
|
125
|
-
VAR_DECLS, {
|
|
126
|
-
// return type
|
|
127
|
-
className: 'type',
|
|
128
|
-
begin: '\\breturn\\s+',
|
|
129
|
-
end: '(\\s+|;|$)',
|
|
130
|
-
keywords: 'return',
|
|
131
|
-
excludeBegin: true,
|
|
132
|
-
excludeEnd: true,
|
|
133
|
-
// we are done with functions
|
|
134
|
-
endsParent: true,
|
|
135
|
-
illegal: BAD_CHARS
|
|
136
|
-
}]
|
|
137
|
-
}, {
|
|
138
|
-
// new type declarations
|
|
139
|
-
// maybe inside generic
|
|
140
|
-
className: 'type',
|
|
141
|
-
begin: '\\b(sub)?type\\s+',
|
|
142
|
-
end: '\\s+',
|
|
143
|
-
keywords: 'type',
|
|
144
|
-
excludeBegin: true,
|
|
145
|
-
illegal: BAD_CHARS
|
|
146
|
-
},
|
|
147
|
-
// see comment above the definition
|
|
148
|
-
VAR_DECLS
|
|
149
|
-
|
|
150
|
-
// no markup
|
|
151
|
-
// relevance boosters for small snippets
|
|
152
|
-
// {begin: '\\s*=>\\s*'},
|
|
153
|
-
// {begin: '\\s*:=\\s*'},
|
|
154
|
-
// {begin: '\\s+:=\\s+'},
|
|
155
|
-
]
|
|
156
|
-
};
|
|
157
|
-
};
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports = function (hljs) {
|
|
4
|
-
var builtInTypeMode = {
|
|
5
|
-
className: 'built_in',
|
|
6
|
-
begin: '\\b(void|bool|int|int8|int16|int32|int64|uint|uint8|uint16|uint32|uint64|string|ref|array|double|float|auto|dictionary)'
|
|
7
|
-
};
|
|
8
|
-
var objectHandleMode = {
|
|
9
|
-
className: 'symbol',
|
|
10
|
-
begin: '[a-zA-Z0-9_]+@'
|
|
11
|
-
};
|
|
12
|
-
var genericMode = {
|
|
13
|
-
className: 'keyword',
|
|
14
|
-
begin: '<',
|
|
15
|
-
end: '>',
|
|
16
|
-
contains: [builtInTypeMode, objectHandleMode]
|
|
17
|
-
};
|
|
18
|
-
builtInTypeMode.contains = [genericMode];
|
|
19
|
-
objectHandleMode.contains = [genericMode];
|
|
20
|
-
return {
|
|
21
|
-
aliases: ['asc'],
|
|
22
|
-
keywords: 'for in|0 break continue while do|0 return if else case switch namespace is cast ' + 'or and xor not get|0 in inout|10 out override set|0 private public const default|0 ' + 'final shared external mixin|10 enum typedef funcdef this super import from interface ' + 'abstract|0 try catch protected explicit',
|
|
23
|
-
// avoid close detection with C# and JS
|
|
24
|
-
illegal: '(^using\\s+[A-Za-z0-9_\\.]+;$|\\bfunction\s*[^\\(])',
|
|
25
|
-
contains: [{
|
|
26
|
-
// 'strings'
|
|
27
|
-
className: 'string',
|
|
28
|
-
begin: '\'',
|
|
29
|
-
end: '\'',
|
|
30
|
-
illegal: '\\n',
|
|
31
|
-
contains: [hljs.BACKSLASH_ESCAPE],
|
|
32
|
-
relevance: 0
|
|
33
|
-
}, {
|
|
34
|
-
// "strings"
|
|
35
|
-
className: 'string',
|
|
36
|
-
begin: '"',
|
|
37
|
-
end: '"',
|
|
38
|
-
illegal: '\\n',
|
|
39
|
-
contains: [hljs.BACKSLASH_ESCAPE],
|
|
40
|
-
relevance: 0
|
|
41
|
-
},
|
|
42
|
-
// """heredoc strings"""
|
|
43
|
-
{
|
|
44
|
-
className: 'string',
|
|
45
|
-
begin: '"""',
|
|
46
|
-
end: '"""'
|
|
47
|
-
}, hljs.C_LINE_COMMENT_MODE,
|
|
48
|
-
// single-line comments
|
|
49
|
-
hljs.C_BLOCK_COMMENT_MODE,
|
|
50
|
-
// comment blocks
|
|
51
|
-
|
|
52
|
-
{
|
|
53
|
-
// interface or namespace declaration
|
|
54
|
-
beginKeywords: 'interface namespace',
|
|
55
|
-
end: '{',
|
|
56
|
-
illegal: '[;.\\-]',
|
|
57
|
-
contains: [{
|
|
58
|
-
// interface or namespace name
|
|
59
|
-
className: 'symbol',
|
|
60
|
-
begin: '[a-zA-Z0-9_]+'
|
|
61
|
-
}]
|
|
62
|
-
}, {
|
|
63
|
-
// class declaration
|
|
64
|
-
beginKeywords: 'class',
|
|
65
|
-
end: '{',
|
|
66
|
-
illegal: '[;.\\-]',
|
|
67
|
-
contains: [{
|
|
68
|
-
// class name
|
|
69
|
-
className: 'symbol',
|
|
70
|
-
begin: '[a-zA-Z0-9_]+',
|
|
71
|
-
contains: [{
|
|
72
|
-
begin: '[:,]\\s*',
|
|
73
|
-
contains: [{
|
|
74
|
-
className: 'symbol',
|
|
75
|
-
begin: '[a-zA-Z0-9_]+'
|
|
76
|
-
}]
|
|
77
|
-
}]
|
|
78
|
-
}]
|
|
79
|
-
}, builtInTypeMode,
|
|
80
|
-
// built-in types
|
|
81
|
-
objectHandleMode,
|
|
82
|
-
// object handles
|
|
83
|
-
|
|
84
|
-
{
|
|
85
|
-
// literals
|
|
86
|
-
className: 'literal',
|
|
87
|
-
begin: '\\b(null|true|false)'
|
|
88
|
-
}, {
|
|
89
|
-
// numbers
|
|
90
|
-
className: 'number',
|
|
91
|
-
begin: '(-?)(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?f?|\\.\\d+f?)([eE][-+]?\\d+f?)?)'
|
|
92
|
-
}]
|
|
93
|
-
};
|
|
94
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports = function (hljs) {
|
|
4
|
-
var NUMBER = {
|
|
5
|
-
className: 'number',
|
|
6
|
-
begin: '[\\$%]\\d+'
|
|
7
|
-
};
|
|
8
|
-
return {
|
|
9
|
-
aliases: ['apacheconf'],
|
|
10
|
-
case_insensitive: true,
|
|
11
|
-
contains: [hljs.HASH_COMMENT_MODE, {
|
|
12
|
-
className: 'section',
|
|
13
|
-
begin: '</?',
|
|
14
|
-
end: '>'
|
|
15
|
-
}, {
|
|
16
|
-
className: 'attribute',
|
|
17
|
-
begin: /\w+/,
|
|
18
|
-
relevance: 0,
|
|
19
|
-
// keywords aren’t needed for highlighting per se, they only boost relevance
|
|
20
|
-
// for a very generally defined mode (starts with a word, ends with line-end
|
|
21
|
-
keywords: {
|
|
22
|
-
nomarkup: 'order deny allow setenv rewriterule rewriteengine rewritecond documentroot ' + 'sethandler errordocument loadmodule options header listen serverroot ' + 'servername'
|
|
23
|
-
},
|
|
24
|
-
starts: {
|
|
25
|
-
end: /$/,
|
|
26
|
-
relevance: 0,
|
|
27
|
-
keywords: {
|
|
28
|
-
literal: 'on off all'
|
|
29
|
-
},
|
|
30
|
-
contains: [{
|
|
31
|
-
className: 'meta',
|
|
32
|
-
begin: '\\s\\[',
|
|
33
|
-
end: '\\]$'
|
|
34
|
-
}, {
|
|
35
|
-
className: 'variable',
|
|
36
|
-
begin: '[\\$%]\\{',
|
|
37
|
-
end: '\\}',
|
|
38
|
-
contains: ['self', NUMBER]
|
|
39
|
-
}, NUMBER, hljs.QUOTE_STRING_MODE]
|
|
40
|
-
}
|
|
41
|
-
}],
|
|
42
|
-
illegal: /\S/
|
|
43
|
-
};
|
|
44
|
-
};
|
|
@@ -1,44 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime-corejs3/helpers/interopRequireDefault");
|
|
4
|
-
var _concat = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/concat"));
|
|
5
|
-
module.exports = function (hljs) {
|
|
6
|
-
var _context;
|
|
7
|
-
var STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {
|
|
8
|
-
illegal: ''
|
|
9
|
-
});
|
|
10
|
-
var PARAMS = {
|
|
11
|
-
className: 'params',
|
|
12
|
-
begin: '\\(',
|
|
13
|
-
end: '\\)',
|
|
14
|
-
contains: ['self', hljs.C_NUMBER_MODE, STRING]
|
|
15
|
-
};
|
|
16
|
-
var COMMENT_MODE_1 = hljs.COMMENT('--', '$');
|
|
17
|
-
var COMMENT_MODE_2 = hljs.COMMENT('\\(\\*', '\\*\\)', {
|
|
18
|
-
contains: ['self', COMMENT_MODE_1] //allow nesting
|
|
19
|
-
});
|
|
20
|
-
var COMMENTS = [COMMENT_MODE_1, COMMENT_MODE_2, hljs.HASH_COMMENT_MODE];
|
|
21
|
-
return {
|
|
22
|
-
aliases: ['osascript'],
|
|
23
|
-
keywords: {
|
|
24
|
-
keyword: 'about above after against and around as at back before beginning ' + 'behind below beneath beside between but by considering ' + 'contain contains continue copy div does eighth else end equal ' + 'equals error every exit fifth first for fourth from front ' + 'get given global if ignoring in into is it its last local me ' + 'middle mod my ninth not of on onto or over prop property put ref ' + 'reference repeat returning script second set seventh since ' + 'sixth some tell tenth that the|0 then third through thru ' + 'timeout times to transaction try until where while whose with ' + 'without',
|
|
25
|
-
literal: 'AppleScript false linefeed return pi quote result space tab true',
|
|
26
|
-
built_in: 'alias application boolean class constant date file integer list ' + 'number real record string text ' + 'activate beep count delay launch log offset read round ' + 'run say summarize write ' + 'character characters contents day frontmost id item length ' + 'month name paragraph paragraphs rest reverse running time version ' + 'weekday word words year'
|
|
27
|
-
},
|
|
28
|
-
contains: (0, _concat.default)(_context = [STRING, hljs.C_NUMBER_MODE, {
|
|
29
|
-
className: 'built_in',
|
|
30
|
-
begin: '\\b(clipboard info|the clipboard|info for|list (disks|folder)|' + 'mount volume|path to|(close|open for) access|(get|set) eof|' + 'current date|do shell script|get volume settings|random number|' + 'set volume|system attribute|system info|time to GMT|' + '(load|run|store) script|scripting components|' + 'ASCII (character|number)|localized string|' + 'choose (application|color|file|file name|' + 'folder|from list|remote application|URL)|' + 'display (alert|dialog))\\b|^\\s*return\\b'
|
|
31
|
-
}, {
|
|
32
|
-
className: 'literal',
|
|
33
|
-
begin: '\\b(text item delimiters|current application|missing value)\\b'
|
|
34
|
-
}, {
|
|
35
|
-
className: 'keyword',
|
|
36
|
-
begin: '\\b(apart from|aside from|instead of|out of|greater than|' + "isn't|(doesn't|does not) (equal|come before|come after|contain)|" + '(greater|less) than( or equal)?|(starts?|ends|begins?) with|' + 'contained by|comes (before|after)|a (ref|reference)|POSIX file|' + 'POSIX path|(date|time) string|quoted form)\\b'
|
|
37
|
-
}, {
|
|
38
|
-
beginKeywords: 'on',
|
|
39
|
-
illegal: '[${=;\\n]',
|
|
40
|
-
contains: [hljs.UNDERSCORE_TITLE_MODE, PARAMS]
|
|
41
|
-
}]).call(_context, COMMENTS),
|
|
42
|
-
illegal: '//|->|=>|\\[\\['
|
|
43
|
-
};
|
|
44
|
-
};
|
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime-corejs3/helpers/interopRequireDefault");
|
|
4
|
-
var _concat = _interopRequireDefault(require("@babel/runtime-corejs3/core-js-stable/instance/concat"));
|
|
5
|
-
module.exports = function (hljs) {
|
|
6
|
-
var _context;
|
|
7
|
-
var IDENT_RE = '[A-Za-z_][0-9A-Za-z_]*';
|
|
8
|
-
var KEYWORDS = {
|
|
9
|
-
keyword: 'if for while var new function do return void else break',
|
|
10
|
-
literal: 'true false null undefined NaN Infinity PI BackSlash DoubleQuote ForwardSlash NewLine SingleQuote Tab',
|
|
11
|
-
built_in: 'Abs Acos Area AreaGeodetic Asin Atan Atan2 Average Boolean Buffer BufferGeodetic ' + 'Ceil Centroid Clip Console Constrain Contains Cos Count Crosses Cut Date DateAdd ' + 'DateDiff Day Decode DefaultValue Dictionary Difference Disjoint Distance Distinct ' + 'DomainCode DomainName Equals Exp Extent Feature FeatureSet FeatureSetById FeatureSetByTitle ' + 'FeatureSetByUrl Filter First Floor Geometry Guid HasKey Hour IIf IndexOf Intersection ' + 'Intersects IsEmpty Length LengthGeodetic Log Max Mean Millisecond Min Minute Month ' + 'MultiPartToSinglePart Multipoint NextSequenceValue Now Number OrderBy Overlaps Point Polygon ' + 'Polyline Pow Random Relate Reverse Round Second SetGeometry Sin Sort Sqrt Stdev Sum ' + 'SymmetricDifference Tan Text Timestamp Today ToLocal Top Touches ToUTC TypeOf Union Variance ' + 'Weekday When Within Year '
|
|
12
|
-
};
|
|
13
|
-
var EXPRESSIONS;
|
|
14
|
-
var SYMBOL = {
|
|
15
|
-
className: 'symbol',
|
|
16
|
-
begin: '\\$[feature|layer|map|value|view]+'
|
|
17
|
-
};
|
|
18
|
-
var NUMBER = {
|
|
19
|
-
className: 'number',
|
|
20
|
-
variants: [{
|
|
21
|
-
begin: '\\b(0[bB][01]+)'
|
|
22
|
-
}, {
|
|
23
|
-
begin: '\\b(0[oO][0-7]+)'
|
|
24
|
-
}, {
|
|
25
|
-
begin: hljs.C_NUMBER_RE
|
|
26
|
-
}],
|
|
27
|
-
relevance: 0
|
|
28
|
-
};
|
|
29
|
-
var SUBST = {
|
|
30
|
-
className: 'subst',
|
|
31
|
-
begin: '\\$\\{',
|
|
32
|
-
end: '\\}',
|
|
33
|
-
keywords: KEYWORDS,
|
|
34
|
-
contains: [] // defined later
|
|
35
|
-
};
|
|
36
|
-
var TEMPLATE_STRING = {
|
|
37
|
-
className: 'string',
|
|
38
|
-
begin: '`',
|
|
39
|
-
end: '`',
|
|
40
|
-
contains: [hljs.BACKSLASH_ESCAPE, SUBST]
|
|
41
|
-
};
|
|
42
|
-
SUBST.contains = [hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE, TEMPLATE_STRING, NUMBER, hljs.REGEXP_MODE];
|
|
43
|
-
var PARAMS_CONTAINS = (0, _concat.default)(_context = SUBST.contains).call(_context, [hljs.C_BLOCK_COMMENT_MODE, hljs.C_LINE_COMMENT_MODE]);
|
|
44
|
-
return {
|
|
45
|
-
aliases: ['arcade'],
|
|
46
|
-
keywords: KEYWORDS,
|
|
47
|
-
contains: [hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE, TEMPLATE_STRING, hljs.C_LINE_COMMENT_MODE, hljs.C_BLOCK_COMMENT_MODE, SYMBOL, NUMBER, {
|
|
48
|
-
// object attr container
|
|
49
|
-
begin: /[{,]\s*/,
|
|
50
|
-
relevance: 0,
|
|
51
|
-
contains: [{
|
|
52
|
-
begin: IDENT_RE + '\\s*:',
|
|
53
|
-
returnBegin: true,
|
|
54
|
-
relevance: 0,
|
|
55
|
-
contains: [{
|
|
56
|
-
className: 'attr',
|
|
57
|
-
begin: IDENT_RE,
|
|
58
|
-
relevance: 0
|
|
59
|
-
}]
|
|
60
|
-
}]
|
|
61
|
-
}, {
|
|
62
|
-
// "value" container
|
|
63
|
-
begin: '(' + hljs.RE_STARTERS_RE + '|\\b(return)\\b)\\s*',
|
|
64
|
-
keywords: 'return',
|
|
65
|
-
contains: [hljs.C_LINE_COMMENT_MODE, hljs.C_BLOCK_COMMENT_MODE, hljs.REGEXP_MODE, {
|
|
66
|
-
className: 'function',
|
|
67
|
-
begin: '(\\(.*?\\)|' + IDENT_RE + ')\\s*=>',
|
|
68
|
-
returnBegin: true,
|
|
69
|
-
end: '\\s*=>',
|
|
70
|
-
contains: [{
|
|
71
|
-
className: 'params',
|
|
72
|
-
variants: [{
|
|
73
|
-
begin: IDENT_RE
|
|
74
|
-
}, {
|
|
75
|
-
begin: /\(\s*\)/
|
|
76
|
-
}, {
|
|
77
|
-
begin: /\(/,
|
|
78
|
-
end: /\)/,
|
|
79
|
-
excludeBegin: true,
|
|
80
|
-
excludeEnd: true,
|
|
81
|
-
keywords: KEYWORDS,
|
|
82
|
-
contains: PARAMS_CONTAINS
|
|
83
|
-
}]
|
|
84
|
-
}]
|
|
85
|
-
}],
|
|
86
|
-
relevance: 0
|
|
87
|
-
}, {
|
|
88
|
-
className: 'function',
|
|
89
|
-
beginKeywords: 'function',
|
|
90
|
-
end: /\{/,
|
|
91
|
-
excludeEnd: true,
|
|
92
|
-
contains: [hljs.inherit(hljs.TITLE_MODE, {
|
|
93
|
-
begin: IDENT_RE
|
|
94
|
-
}), {
|
|
95
|
-
className: 'params',
|
|
96
|
-
begin: /\(/,
|
|
97
|
-
end: /\)/,
|
|
98
|
-
excludeBegin: true,
|
|
99
|
-
excludeEnd: true,
|
|
100
|
-
contains: PARAMS_CONTAINS
|
|
101
|
-
}],
|
|
102
|
-
illegal: /\[|%/
|
|
103
|
-
}, {
|
|
104
|
-
begin: /\$[(.]/
|
|
105
|
-
}],
|
|
106
|
-
illegal: /#(?!!)/
|
|
107
|
-
};
|
|
108
|
-
};
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports = function (hljs) {
|
|
4
|
-
var CPP = hljs.getLanguage('cpp').exports;
|
|
5
|
-
return {
|
|
6
|
-
keywords: {
|
|
7
|
-
keyword: 'boolean byte word string String array ' + CPP.keywords.keyword,
|
|
8
|
-
built_in: 'setup loop while catch for if do goto try switch case else ' + 'default break continue return ' + 'KeyboardController MouseController SoftwareSerial ' + 'EthernetServer EthernetClient LiquidCrystal ' + 'RobotControl GSMVoiceCall EthernetUDP EsploraTFT ' + 'HttpClient RobotMotor WiFiClient GSMScanner ' + 'FileSystem Scheduler GSMServer YunClient YunServer ' + 'IPAddress GSMClient GSMModem Keyboard Ethernet ' + 'Console GSMBand Esplora Stepper Process ' + 'WiFiUDP GSM_SMS Mailbox USBHost Firmata PImage ' + 'Client Server GSMPIN FileIO Bridge Serial ' + 'EEPROM Stream Mouse Audio Servo File Task ' + 'GPRS WiFi Wire TFT GSM SPI SD ' + 'runShellCommandAsynchronously analogWriteResolution ' + 'retrieveCallingNumber printFirmwareVersion ' + 'analogReadResolution sendDigitalPortPair ' + 'noListenOnLocalhost readJoystickButton setFirmwareVersion ' + 'readJoystickSwitch scrollDisplayRight getVoiceCallStatus ' + 'scrollDisplayLeft writeMicroseconds delayMicroseconds ' + 'beginTransmission getSignalStrength runAsynchronously ' + 'getAsynchronously listenOnLocalhost getCurrentCarrier ' + 'readAccelerometer messageAvailable sendDigitalPorts ' + 'lineFollowConfig countryNameWrite runShellCommand ' + 'readStringUntil rewindDirectory readTemperature ' + 'setClockDivider readLightSensor endTransmission ' + 'analogReference detachInterrupt countryNameRead ' + 'attachInterrupt encryptionType readBytesUntil ' + 'robotNameWrite readMicrophone robotNameRead cityNameWrite ' + 'userNameWrite readJoystickY readJoystickX mouseReleased ' + 'openNextFile scanNetworks noInterrupts digitalWrite ' + 'beginSpeaker mousePressed isActionDone mouseDragged ' + 'displayLogos noAutoscroll addParameter remoteNumber ' + 'getModifiers keyboardRead userNameRead waitContinue ' + 'processInput parseCommand printVersion readNetworks ' + 'writeMessage blinkVersion cityNameRead readMessage ' + 'setDataMode parsePacket isListening setBitOrder ' + 'beginPacket isDirectory motorsWrite drawCompass ' + 'digitalRead clearScreen serialEvent rightToLeft ' + 'setTextSize leftToRight requestFrom keyReleased ' + 'compassRead analogWrite interrupts WiFiServer ' + 'disconnect playMelody parseFloat autoscroll ' + 'getPINUsed setPINUsed setTimeout sendAnalog ' + 'readSlider analogRead beginWrite createChar ' + 'motorsStop keyPressed tempoWrite readButton ' + 'subnetMask debugPrint macAddress writeGreen ' + 'randomSeed attachGPRS readString sendString ' + 'remotePort releaseAll mouseMoved background ' + 'getXChange getYChange answerCall getResult ' + 'voiceCall endPacket constrain getSocket writeJSON ' + 'getButton available connected findUntil readBytes ' + 'exitValue readGreen writeBlue startLoop IPAddress ' + 'isPressed sendSysex pauseMode gatewayIP setCursor ' + 'getOemKey tuneWrite noDisplay loadImage switchPIN ' + 'onRequest onReceive changePIN playFile noBuffer ' + 'parseInt overflow checkPIN knobRead beginTFT ' + 'bitClear updateIR bitWrite position writeRGB ' + 'highByte writeRed setSpeed readBlue noStroke ' + 'remoteIP transfer shutdown hangCall beginSMS ' + 'endWrite attached maintain noCursor checkReg ' + 'checkPUK shiftOut isValid shiftIn pulseIn ' + 'connect println localIP pinMode getIMEI ' + 'display noBlink process getBand running beginSD ' + 'drawBMP lowByte setBand release bitRead prepare ' + 'pointTo readRed setMode noFill remove listen ' + 'stroke detach attach noTone exists buffer ' + 'height bitSet circle config cursor random ' + 'IRread setDNS endSMS getKey micros ' + 'millis begin print write ready flush width ' + 'isPIN blink clear press mkdir rmdir close ' + 'point yield image BSSID click delay ' + 'read text move peek beep rect line open ' + 'seek fill size turn stop home find ' + 'step tone sqrt RSSI SSID ' + 'end bit tan cos sin pow map abs max ' + 'min get run put',
|
|
9
|
-
literal: 'DIGITAL_MESSAGE FIRMATA_STRING ANALOG_MESSAGE ' + 'REPORT_DIGITAL REPORT_ANALOG INPUT_PULLUP ' + 'SET_PIN_MODE INTERNAL2V56 SYSTEM_RESET LED_BUILTIN ' + 'INTERNAL1V1 SYSEX_START INTERNAL EXTERNAL ' + 'DEFAULT OUTPUT INPUT HIGH LOW'
|
|
10
|
-
},
|
|
11
|
-
contains: [CPP.preprocessor, hljs.C_LINE_COMMENT_MODE, hljs.C_BLOCK_COMMENT_MODE, hljs.APOS_STRING_MODE, hljs.QUOTE_STRING_MODE, hljs.C_NUMBER_MODE]
|
|
12
|
-
};
|
|
13
|
-
};
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
module.exports = function (hljs) {
|
|
4
|
-
//local labels: %?[FB]?[AT]?\d{1,2}\w+
|
|
5
|
-
return {
|
|
6
|
-
case_insensitive: true,
|
|
7
|
-
aliases: ['arm'],
|
|
8
|
-
lexemes: '\\.?' + hljs.IDENT_RE,
|
|
9
|
-
keywords: {
|
|
10
|
-
meta:
|
|
11
|
-
//GNU preprocs
|
|
12
|
-
'.2byte .4byte .align .ascii .asciz .balign .byte .code .data .else .end .endif .endm .endr .equ .err .exitm .extern .global .hword .if .ifdef .ifndef .include .irp .long .macro .rept .req .section .set .skip .space .text .word .arm .thumb .code16 .code32 .force_thumb .thumb_func .ltorg ' +
|
|
13
|
-
//ARM directives
|
|
14
|
-
'ALIAS ALIGN ARM AREA ASSERT ATTR CN CODE CODE16 CODE32 COMMON CP DATA DCB DCD DCDU DCDO DCFD DCFDU DCI DCQ DCQU DCW DCWU DN ELIF ELSE END ENDFUNC ENDIF ENDP ENTRY EQU EXPORT EXPORTAS EXTERN FIELD FILL FUNCTION GBLA GBLL GBLS GET GLOBAL IF IMPORT INCBIN INCLUDE INFO KEEP LCLA LCLL LCLS LTORG MACRO MAP MEND MEXIT NOFP OPT PRESERVE8 PROC QN READONLY RELOC REQUIRE REQUIRE8 RLIST FN ROUT SETA SETL SETS SN SPACE SUBT THUMB THUMBX TTL WHILE WEND ',
|
|
15
|
-
built_in: 'r0 r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 ' +
|
|
16
|
-
//standard registers
|
|
17
|
-
'pc lr sp ip sl sb fp ' +
|
|
18
|
-
//typical regs plus backward compatibility
|
|
19
|
-
'a1 a2 a3 a4 v1 v2 v3 v4 v5 v6 v7 v8 f0 f1 f2 f3 f4 f5 f6 f7 ' +
|
|
20
|
-
//more regs and fp
|
|
21
|
-
'p0 p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 p11 p12 p13 p14 p15 ' +
|
|
22
|
-
//coprocessor regs
|
|
23
|
-
'c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 c10 c11 c12 c13 c14 c15 ' +
|
|
24
|
-
//more coproc
|
|
25
|
-
'q0 q1 q2 q3 q4 q5 q6 q7 q8 q9 q10 q11 q12 q13 q14 q15 ' +
|
|
26
|
-
//advanced SIMD NEON regs
|
|
27
|
-
|
|
28
|
-
//program status registers
|
|
29
|
-
'cpsr_c cpsr_x cpsr_s cpsr_f cpsr_cx cpsr_cxs cpsr_xs cpsr_xsf cpsr_sf cpsr_cxsf ' + 'spsr_c spsr_x spsr_s spsr_f spsr_cx spsr_cxs spsr_xs spsr_xsf spsr_sf spsr_cxsf ' +
|
|
30
|
-
//NEON and VFP registers
|
|
31
|
-
's0 s1 s2 s3 s4 s5 s6 s7 s8 s9 s10 s11 s12 s13 s14 s15 ' + 's16 s17 s18 s19 s20 s21 s22 s23 s24 s25 s26 s27 s28 s29 s30 s31 ' + 'd0 d1 d2 d3 d4 d5 d6 d7 d8 d9 d10 d11 d12 d13 d14 d15 ' + 'd16 d17 d18 d19 d20 d21 d22 d23 d24 d25 d26 d27 d28 d29 d30 d31 ' + '{PC} {VAR} {TRUE} {FALSE} {OPT} {CONFIG} {ENDIAN} {CODESIZE} {CPU} {FPU} {ARCHITECTURE} {PCSTOREOFFSET} {ARMASM_VERSION} {INTER} {ROPI} {RWPI} {SWST} {NOSWST} . @'
|
|
32
|
-
},
|
|
33
|
-
contains: [{
|
|
34
|
-
className: 'keyword',
|
|
35
|
-
begin: '\\b(' +
|
|
36
|
-
//mnemonics
|
|
37
|
-
'adc|' + '(qd?|sh?|u[qh]?)?add(8|16)?|usada?8|(q|sh?|u[qh]?)?(as|sa)x|' + 'and|adrl?|sbc|rs[bc]|asr|b[lx]?|blx|bxj|cbn?z|tb[bh]|bic|' + 'bfc|bfi|[su]bfx|bkpt|cdp2?|clz|clrex|cmp|cmn|cpsi[ed]|cps|' + 'setend|dbg|dmb|dsb|eor|isb|it[te]{0,3}|lsl|lsr|ror|rrx|' + 'ldm(([id][ab])|f[ds])?|ldr((s|ex)?[bhd])?|movt?|mvn|mra|mar|' + 'mul|[us]mull|smul[bwt][bt]|smu[as]d|smmul|smmla|' + 'mla|umlaal|smlal?([wbt][bt]|d)|mls|smlsl?[ds]|smc|svc|sev|' + 'mia([bt]{2}|ph)?|mrr?c2?|mcrr2?|mrs|msr|orr|orn|pkh(tb|bt)|rbit|' + 'rev(16|sh)?|sel|[su]sat(16)?|nop|pop|push|rfe([id][ab])?|' + 'stm([id][ab])?|str(ex)?[bhd]?|(qd?)?sub|(sh?|q|u[qh]?)?sub(8|16)|' + '[su]xt(a?h|a?b(16)?)|srs([id][ab])?|swpb?|swi|smi|tst|teq|' + 'wfe|wfi|yield' + ')' + '(eq|ne|cs|cc|mi|pl|vs|vc|hi|ls|ge|lt|gt|le|al|hs|lo)?' +
|
|
38
|
-
//condition codes
|
|
39
|
-
'[sptrx]?',
|
|
40
|
-
//legal postfixes
|
|
41
|
-
end: '\\s'
|
|
42
|
-
}, hljs.COMMENT('[;@]', '$', {
|
|
43
|
-
relevance: 0
|
|
44
|
-
}), hljs.C_BLOCK_COMMENT_MODE, hljs.QUOTE_STRING_MODE, {
|
|
45
|
-
className: 'string',
|
|
46
|
-
begin: '\'',
|
|
47
|
-
end: '[^\\\\]\'',
|
|
48
|
-
relevance: 0
|
|
49
|
-
}, {
|
|
50
|
-
className: 'title',
|
|
51
|
-
begin: '\\|',
|
|
52
|
-
end: '\\|',
|
|
53
|
-
illegal: '\\n',
|
|
54
|
-
relevance: 0
|
|
55
|
-
}, {
|
|
56
|
-
className: 'number',
|
|
57
|
-
variants: [{
|
|
58
|
-
begin: '[#$=]?0x[0-9a-f]+'
|
|
59
|
-
},
|
|
60
|
-
//hex
|
|
61
|
-
{
|
|
62
|
-
begin: '[#$=]?0b[01]+'
|
|
63
|
-
},
|
|
64
|
-
//bin
|
|
65
|
-
{
|
|
66
|
-
begin: '[#$=]\\d+'
|
|
67
|
-
},
|
|
68
|
-
//literal
|
|
69
|
-
{
|
|
70
|
-
begin: '\\b\\d+'
|
|
71
|
-
} //bare number
|
|
72
|
-
],
|
|
73
|
-
relevance: 0
|
|
74
|
-
}, {
|
|
75
|
-
className: 'symbol',
|
|
76
|
-
variants: [{
|
|
77
|
-
begin: '^[a-z_\\.\\$][a-z0-9_\\.\\$]+'
|
|
78
|
-
},
|
|
79
|
-
//ARM syntax
|
|
80
|
-
{
|
|
81
|
-
begin: '^\\s*[a-z_\\.\\$][a-z0-9_\\.\\$]+:'
|
|
82
|
-
},
|
|
83
|
-
//GNU ARM syntax
|
|
84
|
-
{
|
|
85
|
-
begin: '[=#]\\w+'
|
|
86
|
-
} //label reference
|
|
87
|
-
],
|
|
88
|
-
relevance: 0
|
|
89
|
-
}]
|
|
90
|
-
};
|
|
91
|
-
};
|