PR['registerLangHandler']( PR['createSimpleLexer']( [ // Whitespace. [PR['PR_PLAIN'], /^[\t\n\r \xA0]+/, null, '\t\n\r \xA0'] ], [ // Multi-line comments [PR['PR_COMMENT'], /#\!(\#(?!\!)|[^!])*\!\#/i], // Single-line comments. [PR['PR_COMMENT'], /(##).*\n?/i], // xml comments [PR['PR_COMMENT'], /^<\!--[\s\S]*?(?:-\->|$)/], // General keywords. [PR['PR_KEYWORD'], /(?:#set|#foreach|#end|#if|#elseif|#else|#parse|#macro|#stop|#include)/i], // Keywords for constants. [PR['PR_KEYWORD'], /^\b(?:false|null|true)\b/i], // Multiline strings, single- and double-quoted. [PR['PR_STRING'], /^r?[\']{3}[\s|\S]*?[^\\][\']{3}/], [PR['PR_STRING'], /^r?[\"]{3}[\s|\S]*?[^\\][\"]{3}/], // Normal and raw strings, single- and double-quoted. [PR['PR_STRING'], /^r?\'(\'|(?:[^\n\r\f])*?[^\\]\')/], [PR['PR_STRING'], /^r?\"(\"|(?:[^\n\r\f])*?[^\\]\")/], // Types are capitalized by convention. // Identifiers. [PR['PR_PLAIN'], /^[a-z_$][a-z0-9_]*/i], // Decimal numbers. [PR['PR_LITERAL'], /^\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i], [PR['PR_LITERAL'], /^\b\.\d+(?:e[+-]?\d+)?/i], ['lang-in.tag', /^(<\/?[a-z][^<>]*>)/i] ]), ['vm']);