]>
luflow.net public git repositories - flow-web.git/blob - static/highlight/es/languages/angelscript.js
1 /*! `angelscript` grammar compiled for Highlight.js 11.11.1 */
2 var hljsGrammar
= (function () {
7 Author: Melissa Geels <melissa@nimble.tools>
9 Website: https://www.angelcode.com/angelscript/
12 /** @type LanguageFn */
13 function angelscript(hljs
) {
14 const builtInTypeMode
= {
15 className: 'built_in',
16 begin: '\\b(void|bool|int8|int16|int32|int64|int|uint8|uint16|uint32|uint64|uint|string|ref|array|double|float|auto|dictionary)'
19 const objectHandleMode
= {
21 begin: '[a-zA-Z0-9_]+@'
34 builtInTypeMode
.contains
= [ genericMode
];
35 objectHandleMode
.contains
= [ genericMode
];
92 // avoid close detection with C# and JS
93 illegal: '(^using\\s+[A-Za-z0-9_\\.]+;$|\\bfunction\\s*[^\\(])',
101 contains: [ hljs
.BACKSLASH_ESCAPE
],
105 // """heredoc strings"""
117 contains: [ hljs
.BACKSLASH_ESCAPE
],
121 hljs
.C_LINE_COMMENT_MODE
, // single-line comments
122 hljs
.C_BLOCK_COMMENT_MODE
, // comment blocks
130 { // interface or namespace declaration
131 beginKeywords: 'interface namespace',
135 { // interface or namespace name
137 begin: '[a-zA-Z0-9_]+'
142 { // class declaration
143 beginKeywords: 'class',
149 begin: '[a-zA-Z0-9_]+',
156 begin: '[a-zA-Z0-9_]+'
165 builtInTypeMode
, // built-in types
166 objectHandleMode
, // object handles
169 className: 'literal',
170 begin: '\\b(null|true|false)'
176 begin: '(-?)(\\b0[xXbBoOdD][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?f?|\\.\\d+f?)([eE][-+]?\\d+f?)?)'
186 export default hljsGrammar
;