text/js/highlight/crystal.js.map

1 строка
9.5 KiB
Plaintext

{"version":3,"sources":["webpack:///./node_modules/highlight.js/lib/languages/crystal.js"],"names":["module","exports","hljs","INT_SUFFIX","CRYSTAL_METHOD_RE","CRYSTAL_KEYWORDS","$pattern","keyword","literal","SUBST","className","begin","end","keywords","EXPANSION","variants","recursiveParen","contains","STRING","BACKSLASH_ESCAPE","relevance","Q_STRING","REGEXP","RE_STARTERS_RE","CRYSTAL_DEFAULT_CONTAINS","inherit","QUOTE_STRING_MODE","HASH_COMMENT_MODE","beginKeywords","illegal","TITLE_MODE","endsParent","UNDERSCORE_IDENT_RE","slice","name","aliases"],"mappings":"mGAoMAA,EAAOC,QA7LP,SAAiBC,GACf,IAAIC,EAAa,4BAGbC,EAAoB,gHAEpBC,EAAmB,CACrBC,SAJqB,sBAKrBC,QACE,yYAIFC,QAAS,kBAEPC,EAAQ,CACVC,UAAW,QACXC,MAAO,MAAOC,IAAK,KACnBC,SAAUR,GAERS,EAAY,CACdJ,UAAW,oBACXK,SAAU,CACR,CAACJ,MAAO,SAAUC,IAAK,UACvB,CAACD,MAAO,OAAQC,IAAK,SAEvBC,SAAUR,GAGZ,SAASW,EAAeL,EAAOC,GAC7B,IACAK,EAAW,CAAC,CAACN,MAAOA,EAAOC,IAAKA,IAEhC,OADAK,EAAS,GAAGA,SAAWA,EAChBA,EAET,IAAIC,EAAS,CACXR,UAAW,SACXO,SAAU,CAACf,EAAKiB,iBAAkBV,GAClCM,SAAU,CACR,CAACJ,MAAO,IAAKC,IAAK,KAClB,CAACD,MAAO,IAAKC,IAAK,KAClB,CAACD,MAAO,IAAKC,IAAK,KAClB,CAACD,MAAO,aAAcC,IAAK,MAAOK,SAAUD,EAAe,MAAO,QAClE,CAACL,MAAO,aAAcC,IAAK,MAAOK,SAAUD,EAAe,MAAO,QAClE,CAACL,MAAO,aAAcC,IAAK,KAAMK,SAAUD,EAAe,KAAM,OAChE,CAACL,MAAO,WAAYC,IAAK,IAAKK,SAAUD,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sune <make.just.on@gmail.com>\nWebsite: https://crystal-lang.org\n*/\n\n/** @type LanguageFn */\nfunction crystal(hljs) {\n var INT_SUFFIX = '(_?[ui](8|16|32|64|128))?';\n var FLOAT_SUFFIX = '(_?f(32|64))?';\n var CRYSTAL_IDENT_RE = '[a-zA-Z_]\\\\w*[!?=]?';\n var CRYSTAL_METHOD_RE = '[a-zA-Z_]\\\\w*[!?=]?|[-+~]@|<<|>>|[=!]~|===?|<=>|[<>]=?|\\\\*\\\\*|[-/+%^&*~|]|//|//=|&[-+*]=?|&\\\\*\\\\*|\\\\[\\\\][=?]?';\n var CRYSTAL_PATH_RE = '[A-Za-z_]\\\\w*(::\\\\w+)*(\\\\?|!)?';\n var CRYSTAL_KEYWORDS = {\n $pattern: CRYSTAL_IDENT_RE,\n keyword:\n 'abstract alias annotation as as? asm begin break case class def do else elsif end ensure enum extend for fun if ' +\n 'include instance_sizeof is_a? lib macro module next nil? of out pointerof private protected rescue responds_to? ' +\n 'return require select self sizeof struct super then type typeof union uninitialized unless until verbatim when while with yield ' +\n '__DIR__ __END_LINE__ __FILE__ __LINE__',\n literal: 'false nil true'\n };\n var SUBST = {\n className: 'subst',\n begin: /#\\{/, end: /\\}/,\n keywords: CRYSTAL_KEYWORDS\n };\n var EXPANSION = {\n className: 'template-variable',\n variants: [\n {begin: '\\\\{\\\\{', end: '\\\\}\\\\}'},\n {begin: '\\\\{%', end: '%\\\\}'}\n ],\n keywords: CRYSTAL_KEYWORDS\n };\n\n function recursiveParen(begin, end) {\n var\n contains = [{begin: begin, end: end}];\n contains[0].contains = contains;\n return contains;\n }\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /'/, end: /'/},\n {begin: /\"/, end: /\"/},\n {begin: /`/, end: /`/},\n {begin: '%[Qwi]?\\\\(', end: '\\\\)', contains: recursiveParen('\\\\(', '\\\\)')},\n {begin: '%[Qwi]?\\\\[', end: '\\\\]', contains: recursiveParen('\\\\[', '\\\\]')},\n {begin: '%[Qwi]?\\\\{', end: /\\}/, contains: recursiveParen(/\\{/, /\\}/)},\n {begin: '%[Qwi]?<', end: '>', contains: recursiveParen('<', '>')},\n {begin: '%[Qwi]?\\\\|', end: '\\\\|'},\n {begin: /<<-\\w+$/, end: /^\\s*\\w+$/},\n ],\n relevance: 0,\n };\n var Q_STRING = {\n className: 'string',\n variants: [\n {begin: '%q\\\\(', end: '\\\\)', contains: recursiveParen('\\\\(', '\\\\)')},\n {begin: '%q\\\\[', end: '\\\\]', contains: recursiveParen('\\\\[', '\\\\]')},\n {begin: '%q\\\\{', end: /\\}/, contains: recursiveParen(/\\{/, /\\}/)},\n {begin: '%q<', end: '>', contains: recursiveParen('<', '>')},\n {begin: '%q\\\\|', end: '\\\\|'},\n {begin: /<<-'\\w+'$/, end: /^\\s*\\w+$/},\n ],\n relevance: 0,\n };\n var REGEXP = {\n begin: '(?!%\\\\})(' + hljs.RE_STARTERS_RE + '|\\\\n|\\\\b(case|if|select|unless|until|when|while)\\\\b)\\\\s*',\n keywords: 'case if select unless until when while',\n contains: [\n {\n className: 'regexp',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: '//[a-z]*', relevance: 0},\n {begin: '/(?!\\\\/)', end: '/[a-z]*'},\n ]\n }\n ],\n relevance: 0\n };\n var REGEXP2 = {\n className: 'regexp',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: '%r\\\\(', end: '\\\\)', contains: recursiveParen('\\\\(', '\\\\)')},\n {begin: '%r\\\\[', end: '\\\\]', contains: recursiveParen('\\\\[', '\\\\]')},\n {begin: '%r\\\\{', end: /\\}/, contains: recursiveParen(/\\{/, /\\}/)},\n {begin: '%r<', end: '>', contains: recursiveParen('<', '>')},\n {begin: '%r\\\\|', end: '\\\\|'},\n ],\n relevance: 0\n };\n var ATTRIBUTE = {\n className: 'meta',\n begin: '@\\\\[', end: '\\\\]',\n contains: [\n hljs.inherit(hljs.QUOTE_STRING_MODE, {className: 'meta-string'})\n ]\n };\n var CRYSTAL_DEFAULT_CONTAINS = [\n EXPANSION,\n STRING,\n Q_STRING,\n REGEXP2,\n REGEXP,\n ATTRIBUTE,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'class',\n beginKeywords: 'class module struct', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.HASH_COMMENT_MODE,\n hljs.inherit(hljs.TITLE_MODE, {begin: CRYSTAL_PATH_RE}),\n {begin: '<'} // relevance booster for inheritance\n ]\n },\n {\n className: 'class',\n beginKeywords: 'lib enum union', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.HASH_COMMENT_MODE,\n hljs.inherit(hljs.TITLE_MODE, {begin: CRYSTAL_PATH_RE}),\n ],\n relevance: 10\n },\n {\n beginKeywords: 'annotation', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.HASH_COMMENT_MODE,\n hljs.inherit(hljs.TITLE_MODE, {begin: CRYSTAL_PATH_RE}),\n ],\n relevance: 10\n },\n {\n className: 'function',\n beginKeywords: 'def', end: /\\B\\b/,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: CRYSTAL_METHOD_RE,\n endsParent: true\n })\n ]\n },\n {\n className: 'function',\n beginKeywords: 'fun macro', end: /\\B\\b/,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: CRYSTAL_METHOD_RE,\n endsParent: true\n })\n ],\n relevance: 2\n },\n {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '(!|\\\\?)?:',\n relevance: 0\n },\n {\n className: 'symbol',\n begin: ':',\n contains: [STRING, {begin: CRYSTAL_METHOD_RE}],\n relevance: 0\n },\n {\n className: 'number',\n variants: [\n { begin: '\\\\b0b([01_]+)' + INT_SUFFIX },\n { begin: '\\\\b0o([0-7_]+)' + INT_SUFFIX },\n { begin: '\\\\b0x([A-Fa-f0-9_]+)' + INT_SUFFIX },\n { begin: '\\\\b([1-9][0-9_]*[0-9]|[0-9])(\\\\.[0-9][0-9_]*)?([eE]_?[-+]?[0-9_]*)?' + FLOAT_SUFFIX + '(?!_)' },\n { begin: '\\\\b([1-9][0-9_]*|0)' + INT_SUFFIX }\n ],\n relevance: 0\n }\n ];\n SUBST.contains = CRYSTAL_DEFAULT_CONTAINS;\n EXPANSION.contains = CRYSTAL_DEFAULT_CONTAINS.slice(1); // without EXPANSION\n\n return {\n name: 'Crystal',\n aliases: ['cr'],\n keywords: CRYSTAL_KEYWORDS,\n contains: CRYSTAL_DEFAULT_CONTAINS\n };\n}\n\nmodule.exports = crystal;\n"],"sourceRoot":""}