blob: 242af19b4300b07334adadc684a3223fd1960e15 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
Prism.languages.meson= {
'triple-quoted-string': {
'pattern': /'''[\s\S]*?'''/,
'alias': 'string'
},
'comment': /#.*/,
'string': /'(?:\\'|[^'])*'/,
'number': /\b\d+(?:\.\d+)?\b/,
'keyword': /\b(?:if|else|elif|endif|foreach|endforeach)\b/,
'function': /(?=\.|\b)[a-zA-Z_]+\s*(?=\()/,
'boolean': /\b(?:true|false)\b/,
'builtin': /\b(?:meson|host_machine|target_machine|build_machine)(?=\.)/,
'operator': /(?:[<>=*+\-/!]?=|%|\/|\*|-|\+|\b(?:or|and|not)\b)/,
'punctuation': /[(),[\]]/
// TODO: Handle ternary ?:
};
|