react-ai-renderer 0.1.5 → 0.1.6

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.cjs CHANGED
@@ -8543,12 +8543,12 @@ function ruby(Prism) {
8543
8543
  })(Prism);
8544
8544
  }
8545
8545
 
8546
- var refractorRuby$1 = ruby_1;
8546
+ var refractorRuby = ruby_1;
8547
8547
  var crystal_1 = crystal;
8548
8548
  crystal.displayName = 'crystal';
8549
8549
  crystal.aliases = [];
8550
8550
  function crystal(Prism) {
8551
- Prism.register(refractorRuby$1)
8551
+ Prism.register(refractorRuby)
8552
8552
  ;(function (Prism) {
8553
8553
  Prism.languages.crystal = Prism.languages.extend('ruby', {
8554
8554
  keyword: [
@@ -9026,44 +9026,53 @@ function csv(Prism) {
9026
9026
  };
9027
9027
  }
9028
9028
 
9029
- var cypher_1 = cypher;
9030
- cypher.displayName = 'cypher';
9031
- cypher.aliases = [];
9032
- function cypher(Prism) {
9033
- Prism.languages.cypher = {
9034
- // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
9035
- comment: /\/\/.*/,
9036
- string: {
9037
- pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
9038
- greedy: true
9039
- },
9040
- 'class-name': {
9041
- pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
9042
- lookbehind: true,
9043
- greedy: true
9044
- },
9045
- relationship: {
9046
- pattern:
9047
- /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
9048
- lookbehind: true,
9049
- greedy: true,
9050
- alias: 'property'
9051
- },
9052
- identifier: {
9053
- pattern: /`(?:[^`\\\r\n])*`/,
9054
- greedy: true
9055
- },
9056
- variable: /\$\w+/,
9057
- // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
9058
- keyword:
9059
- /\b(?:ADD|ALL|AND|AS|ASC|ASCENDING|ASSERT|BY|CALL|CASE|COMMIT|CONSTRAINT|CONTAINS|CREATE|CSV|DELETE|DESC|DESCENDING|DETACH|DISTINCT|DO|DROP|ELSE|END|ENDS|EXISTS|FOR|FOREACH|IN|INDEX|IS|JOIN|KEY|LIMIT|LOAD|MANDATORY|MATCH|MERGE|NODE|NOT|OF|ON|OPTIONAL|OR|ORDER(?=\s+BY)|PERIODIC|REMOVE|REQUIRE|RETURN|SCALAR|SCAN|SET|SKIP|START|STARTS|THEN|UNION|UNIQUE|UNWIND|USING|WHEN|WHERE|WITH|XOR|YIELD)\b/i,
9060
- function: /\b\w+\b(?=\s*\()/,
9061
- boolean: /\b(?:false|null|true)\b/i,
9062
- number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
9063
- // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
9064
- operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
9065
- punctuation: /[()[\]{},;.]/
9066
- };
9029
+ var cypher_1;
9030
+ var hasRequiredCypher;
9031
+
9032
+ function requireCypher () {
9033
+ if (hasRequiredCypher) return cypher_1;
9034
+ hasRequiredCypher = 1;
9035
+
9036
+ cypher_1 = cypher;
9037
+ cypher.displayName = 'cypher';
9038
+ cypher.aliases = [];
9039
+ function cypher(Prism) {
9040
+ Prism.languages.cypher = {
9041
+ // https://neo4j.com/docs/cypher-manual/current/syntax/comments/
9042
+ comment: /\/\/.*/,
9043
+ string: {
9044
+ pattern: /"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,
9045
+ greedy: true
9046
+ },
9047
+ 'class-name': {
9048
+ pattern: /(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,
9049
+ lookbehind: true,
9050
+ greedy: true
9051
+ },
9052
+ relationship: {
9053
+ pattern:
9054
+ /(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,
9055
+ lookbehind: true,
9056
+ greedy: true,
9057
+ alias: 'property'
9058
+ },
9059
+ identifier: {
9060
+ pattern: /`(?:[^`\\\r\n])*`/,
9061
+ greedy: true
9062
+ },
9063
+ variable: /\$\w+/,
9064
+ // https://neo4j.com/docs/cypher-manual/current/syntax/reserved/
9065
+ keyword:
9066
+ /\b(?:ADD|ALL|AND|AS|ASC|ASCENDING|ASSERT|BY|CALL|CASE|COMMIT|CONSTRAINT|CONTAINS|CREATE|CSV|DELETE|DESC|DESCENDING|DETACH|DISTINCT|DO|DROP|ELSE|END|ENDS|EXISTS|FOR|FOREACH|IN|INDEX|IS|JOIN|KEY|LIMIT|LOAD|MANDATORY|MATCH|MERGE|NODE|NOT|OF|ON|OPTIONAL|OR|ORDER(?=\s+BY)|PERIODIC|REMOVE|REQUIRE|RETURN|SCALAR|SCAN|SET|SKIP|START|STARTS|THEN|UNION|UNIQUE|UNWIND|USING|WHEN|WHERE|WITH|XOR|YIELD)\b/i,
9067
+ function: /\b\w+\b(?=\s*\()/,
9068
+ boolean: /\b(?:false|null|true)\b/i,
9069
+ number: /\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,
9070
+ // https://neo4j.com/docs/cypher-manual/current/syntax/operators/
9071
+ operator: /:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,
9072
+ punctuation: /[()[\]{},;.]/
9073
+ };
9074
+ }
9075
+ return cypher_1;
9067
9076
  }
9068
9077
 
9069
9078
  var d_1 = d;
@@ -9152,88 +9161,97 @@ function d(Prism) {
9152
9161
  });
9153
9162
  }
9154
9163
 
9155
- var dart_1 = dart;
9156
- dart.displayName = 'dart';
9157
- dart.aliases = [];
9158
- function dart(Prism) {
9164
+ var dart_1;
9165
+ var hasRequiredDart;
9166
+
9167
+ function requireDart () {
9168
+ if (hasRequiredDart) return dart_1;
9169
+ hasRequiredDart = 1;
9170
+
9171
+ dart_1 = dart;
9172
+ dart.displayName = 'dart';
9173
+ dart.aliases = [];
9174
+ function dart(Prism) {
9159
9175
  (function (Prism) {
9160
- var keywords = [
9161
- /\b(?:async|sync|yield)\*/,
9162
- /\b(?:abstract|assert|async|await|break|case|catch|class|const|continue|covariant|default|deferred|do|dynamic|else|enum|export|extends|extension|external|factory|final|finally|for|get|hide|if|implements|import|in|interface|library|mixin|new|null|on|operator|part|rethrow|return|set|show|static|super|switch|sync|this|throw|try|typedef|var|void|while|with|yield)\b/
9163
- ]; // Handles named imports, such as http.Client
9164
- var packagePrefix = /(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/
9165
- .source; // based on the dart naming conventions
9166
- var className = {
9167
- pattern: RegExp(packagePrefix + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
9168
- lookbehind: true,
9169
- inside: {
9170
- namespace: {
9171
- pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
9172
- inside: {
9173
- punctuation: /\./
9174
- }
9175
- }
9176
- }
9177
- };
9178
- Prism.languages.dart = Prism.languages.extend('clike', {
9179
- 'class-name': [
9180
- className,
9181
- {
9182
- // variables and parameters
9183
- // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
9184
- pattern: RegExp(
9185
- packagePrefix + /[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source
9186
- ),
9187
- lookbehind: true,
9188
- inside: className.inside
9189
- }
9190
- ],
9191
- keyword: keywords,
9192
- operator:
9193
- /\bis!|\b(?:as|is)\b|\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?/
9194
- });
9195
- Prism.languages.insertBefore('dart', 'string', {
9196
- 'string-literal': {
9197
- pattern:
9198
- /r?(?:("""|''')[\s\S]*?\1|(["'])(?:\\.|(?!\2)[^\\\r\n])*\2(?!\2))/,
9199
- greedy: true,
9200
- inside: {
9201
- interpolation: {
9202
- pattern:
9203
- /((?:^|[^\\])(?:\\{2})*)\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,
9204
- lookbehind: true,
9205
- inside: {
9206
- punctuation: /^\$\{?|\}$/,
9207
- expression: {
9208
- pattern: /[\s\S]+/,
9209
- inside: Prism.languages.dart
9210
- }
9211
- }
9212
- },
9213
- string: /[\s\S]+/
9214
- }
9215
- },
9216
- string: undefined
9217
- });
9218
- Prism.languages.insertBefore('dart', 'class-name', {
9219
- metadata: {
9220
- pattern: /@\w+/,
9221
- alias: 'function'
9222
- }
9223
- });
9224
- Prism.languages.insertBefore('dart', 'class-name', {
9225
- generics: {
9226
- pattern:
9227
- /<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<[\w\s,.&?]*>)*>)*>)*>/,
9228
- inside: {
9229
- 'class-name': className,
9230
- keyword: keywords,
9231
- punctuation: /[<>(),.:]/,
9232
- operator: /[?&|]/
9233
- }
9234
- }
9235
- });
9236
- })(Prism);
9176
+ var keywords = [
9177
+ /\b(?:async|sync|yield)\*/,
9178
+ /\b(?:abstract|assert|async|await|break|case|catch|class|const|continue|covariant|default|deferred|do|dynamic|else|enum|export|extends|extension|external|factory|final|finally|for|get|hide|if|implements|import|in|interface|library|mixin|new|null|on|operator|part|rethrow|return|set|show|static|super|switch|sync|this|throw|try|typedef|var|void|while|with|yield)\b/
9179
+ ]; // Handles named imports, such as http.Client
9180
+ var packagePrefix = /(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/
9181
+ .source; // based on the dart naming conventions
9182
+ var className = {
9183
+ pattern: RegExp(packagePrefix + /[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),
9184
+ lookbehind: true,
9185
+ inside: {
9186
+ namespace: {
9187
+ pattern: /^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,
9188
+ inside: {
9189
+ punctuation: /\./
9190
+ }
9191
+ }
9192
+ }
9193
+ };
9194
+ Prism.languages.dart = Prism.languages.extend('clike', {
9195
+ 'class-name': [
9196
+ className,
9197
+ {
9198
+ // variables and parameters
9199
+ // this to support class names (or generic parameters) which do not contain a lower case letter (also works for methods)
9200
+ pattern: RegExp(
9201
+ packagePrefix + /[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source
9202
+ ),
9203
+ lookbehind: true,
9204
+ inside: className.inside
9205
+ }
9206
+ ],
9207
+ keyword: keywords,
9208
+ operator:
9209
+ /\bis!|\b(?:as|is)\b|\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?/
9210
+ });
9211
+ Prism.languages.insertBefore('dart', 'string', {
9212
+ 'string-literal': {
9213
+ pattern:
9214
+ /r?(?:("""|''')[\s\S]*?\1|(["'])(?:\\.|(?!\2)[^\\\r\n])*\2(?!\2))/,
9215
+ greedy: true,
9216
+ inside: {
9217
+ interpolation: {
9218
+ pattern:
9219
+ /((?:^|[^\\])(?:\\{2})*)\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,
9220
+ lookbehind: true,
9221
+ inside: {
9222
+ punctuation: /^\$\{?|\}$/,
9223
+ expression: {
9224
+ pattern: /[\s\S]+/,
9225
+ inside: Prism.languages.dart
9226
+ }
9227
+ }
9228
+ },
9229
+ string: /[\s\S]+/
9230
+ }
9231
+ },
9232
+ string: undefined
9233
+ });
9234
+ Prism.languages.insertBefore('dart', 'class-name', {
9235
+ metadata: {
9236
+ pattern: /@\w+/,
9237
+ alias: 'function'
9238
+ }
9239
+ });
9240
+ Prism.languages.insertBefore('dart', 'class-name', {
9241
+ generics: {
9242
+ pattern:
9243
+ /<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<[\w\s,.&?]*>)*>)*>)*>/,
9244
+ inside: {
9245
+ 'class-name': className,
9246
+ keyword: keywords,
9247
+ punctuation: /[<>(),.:]/,
9248
+ operator: /[?&|]/
9249
+ }
9250
+ }
9251
+ });
9252
+ })(Prism);
9253
+ }
9254
+ return dart_1;
9237
9255
  }
9238
9256
 
9239
9257
  var dataweave_1 = dataweave;
@@ -9320,89 +9338,80 @@ function dax(Prism) {
9320
9338
  };
9321
9339
  }
9322
9340
 
9323
- var dhall_1;
9324
- var hasRequiredDhall;
9325
-
9326
- function requireDhall () {
9327
- if (hasRequiredDhall) return dhall_1;
9328
- hasRequiredDhall = 1;
9329
-
9330
- dhall_1 = dhall;
9331
- dhall.displayName = 'dhall';
9332
- dhall.aliases = [];
9333
- function dhall(Prism) {
9334
- // ABNF grammar:
9335
- // https://github.com/dhall-lang/dhall-lang/blob/master/standard/dhall.abnf
9336
- Prism.languages.dhall = {
9337
- // Multi-line comments can be nested. E.g. {- foo {- bar -} -}
9338
- // The multi-line pattern is essentially this:
9339
- // \{-(?:[^-{]|-(?!\})|\{(?!-)|<SELF>)*-\}
9340
- comment:
9341
- /--.*|\{-(?:[^-{]|-(?!\})|\{(?!-)|\{-(?:[^-{]|-(?!\})|\{(?!-))*-\})*-\}/,
9342
- string: {
9343
- pattern: /"(?:[^"\\]|\\.)*"|''(?:[^']|'(?!')|'''|''\$\{)*''(?!'|\$)/,
9344
- greedy: true,
9345
- inside: {
9346
- interpolation: {
9347
- pattern: /\$\{[^{}]*\}/,
9348
- inside: {
9349
- expression: {
9350
- pattern: /(^\$\{)[\s\S]+(?=\}$)/,
9351
- lookbehind: true,
9352
- alias: 'language-dhall',
9353
- inside: null // see blow
9354
- },
9355
- punctuation: /\$\{|\}/
9356
- }
9357
- }
9358
- }
9359
- },
9360
- label: {
9361
- pattern: /`[^`]*`/,
9362
- greedy: true
9363
- },
9364
- url: {
9365
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L596
9366
- pattern:
9367
- /\bhttps?:\/\/[\w.:%!$&'*+;=@~-]+(?:\/[\w.:%!$&'*+;=@~-]*)*(?:\?[/?\w.:%!$&'*+;=@~-]*)?/,
9368
- greedy: true
9369
- },
9370
- env: {
9371
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L661
9372
- pattern: /\benv:(?:(?!\d)\w+|"(?:[^"\\=]|\\.)*")/,
9373
- greedy: true,
9374
- inside: {
9375
- function: /^env/,
9376
- operator: /^:/,
9377
- variable: /[\s\S]+/
9378
- }
9379
- },
9380
- hash: {
9381
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L725
9382
- pattern: /\bsha256:[\da-fA-F]{64}\b/,
9383
- inside: {
9384
- function: /sha256/,
9385
- operator: /:/,
9386
- number: /[\da-fA-F]{64}/
9387
- }
9388
- },
9389
- // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L359
9390
- keyword:
9391
- /\b(?:as|assert|else|forall|if|in|let|merge|missing|then|toMap|using|with)\b|\u2200/,
9392
- builtin: /\b(?:None|Some)\b/,
9393
- boolean: /\b(?:False|True)\b/,
9394
- number:
9395
- /\bNaN\b|-?\bInfinity\b|[+-]?\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/,
9396
- operator:
9397
- /\/\\|\/\/\\\\|&&|\|\||===|[!=]=|\/\/|->|\+\+|::|[+*#@=:?<>|\\\u2227\u2a53\u2261\u2afd\u03bb\u2192]/,
9398
- punctuation: /\.\.|[{}\[\](),./]/,
9399
- // we'll just assume that every capital word left is a type name
9400
- 'class-name': /\b[A-Z]\w*\b/
9401
- };
9402
- Prism.languages.dhall.string.inside.interpolation.inside.expression.inside =
9403
- Prism.languages.dhall;
9404
- }
9405
- return dhall_1;
9341
+ var dhall_1 = dhall;
9342
+ dhall.displayName = 'dhall';
9343
+ dhall.aliases = [];
9344
+ function dhall(Prism) {
9345
+ // ABNF grammar:
9346
+ // https://github.com/dhall-lang/dhall-lang/blob/master/standard/dhall.abnf
9347
+ Prism.languages.dhall = {
9348
+ // Multi-line comments can be nested. E.g. {- foo {- bar -} -}
9349
+ // The multi-line pattern is essentially this:
9350
+ // \{-(?:[^-{]|-(?!\})|\{(?!-)|<SELF>)*-\}
9351
+ comment:
9352
+ /--.*|\{-(?:[^-{]|-(?!\})|\{(?!-)|\{-(?:[^-{]|-(?!\})|\{(?!-))*-\})*-\}/,
9353
+ string: {
9354
+ pattern: /"(?:[^"\\]|\\.)*"|''(?:[^']|'(?!')|'''|''\$\{)*''(?!'|\$)/,
9355
+ greedy: true,
9356
+ inside: {
9357
+ interpolation: {
9358
+ pattern: /\$\{[^{}]*\}/,
9359
+ inside: {
9360
+ expression: {
9361
+ pattern: /(^\$\{)[\s\S]+(?=\}$)/,
9362
+ lookbehind: true,
9363
+ alias: 'language-dhall',
9364
+ inside: null // see blow
9365
+ },
9366
+ punctuation: /\$\{|\}/
9367
+ }
9368
+ }
9369
+ }
9370
+ },
9371
+ label: {
9372
+ pattern: /`[^`]*`/,
9373
+ greedy: true
9374
+ },
9375
+ url: {
9376
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L596
9377
+ pattern:
9378
+ /\bhttps?:\/\/[\w.:%!$&'*+;=@~-]+(?:\/[\w.:%!$&'*+;=@~-]*)*(?:\?[/?\w.:%!$&'*+;=@~-]*)?/,
9379
+ greedy: true
9380
+ },
9381
+ env: {
9382
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L661
9383
+ pattern: /\benv:(?:(?!\d)\w+|"(?:[^"\\=]|\\.)*")/,
9384
+ greedy: true,
9385
+ inside: {
9386
+ function: /^env/,
9387
+ operator: /^:/,
9388
+ variable: /[\s\S]+/
9389
+ }
9390
+ },
9391
+ hash: {
9392
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L725
9393
+ pattern: /\bsha256:[\da-fA-F]{64}\b/,
9394
+ inside: {
9395
+ function: /sha256/,
9396
+ operator: /:/,
9397
+ number: /[\da-fA-F]{64}/
9398
+ }
9399
+ },
9400
+ // https://github.com/dhall-lang/dhall-lang/blob/5fde8ef1bead6fb4e999d3c1ffe7044cd019d63a/standard/dhall.abnf#L359
9401
+ keyword:
9402
+ /\b(?:as|assert|else|forall|if|in|let|merge|missing|then|toMap|using|with)\b|\u2200/,
9403
+ builtin: /\b(?:None|Some)\b/,
9404
+ boolean: /\b(?:False|True)\b/,
9405
+ number:
9406
+ /\bNaN\b|-?\bInfinity\b|[+-]?\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/,
9407
+ operator:
9408
+ /\/\\|\/\/\\\\|&&|\|\||===|[!=]=|\/\/|->|\+\+|::|[+*#@=:?<>|\\\u2227\u2a53\u2261\u2afd\u03bb\u2192]/,
9409
+ punctuation: /\.\.|[{}\[\](),./]/,
9410
+ // we'll just assume that every capital word left is a type name
9411
+ 'class-name': /\b[A-Z]\w*\b/
9412
+ };
9413
+ Prism.languages.dhall.string.inside.interpolation.inside.expression.inside =
9414
+ Prism.languages.dhall;
9406
9415
  }
9407
9416
 
9408
9417
  var diff_1 = diff;
@@ -9595,96 +9604,104 @@ function requireMarkupTemplating () {
9595
9604
  return markupTemplating_1;
9596
9605
  }
9597
9606
 
9598
- var refractorMarkupTemplating$3 = requireMarkupTemplating();
9599
- var django_1 = django;
9600
- django.displayName = 'django';
9601
- django.aliases = ['jinja2'];
9602
- function django(Prism) {
9603
- Prism.register(refractorMarkupTemplating$3)
9604
- // Django/Jinja2 syntax definition for Prism.js <http://prismjs.com> syntax highlighter.
9605
- // Mostly it works OK but can paint code incorrectly on complex html/template tag combinations.
9606
- ;(function (Prism) {
9607
- Prism.languages.django = {
9608
- comment: /^\{#[\s\S]*?#\}$/,
9609
- tag: {
9610
- pattern: /(^\{%[+-]?\s*)\w+/,
9611
- lookbehind: true,
9612
- alias: 'keyword'
9613
- },
9614
- delimiter: {
9615
- pattern: /^\{[{%][+-]?|[+-]?[}%]\}$/,
9616
- alias: 'punctuation'
9617
- },
9618
- string: {
9619
- pattern: /("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
9620
- greedy: true
9621
- },
9622
- filter: {
9623
- pattern: /(\|)\w+/,
9624
- lookbehind: true,
9625
- alias: 'function'
9626
- },
9627
- test: {
9628
- pattern: /(\bis\s+(?:not\s+)?)(?!not\b)\w+/,
9629
- lookbehind: true,
9630
- alias: 'function'
9631
- },
9632
- function: /\b[a-z_]\w+(?=\s*\()/i,
9633
- keyword:
9634
- /\b(?:and|as|by|else|for|if|import|in|is|loop|not|or|recursive|with|without)\b/,
9635
- operator: /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
9636
- number: /\b\d+(?:\.\d+)?\b/,
9637
- boolean: /[Ff]alse|[Nn]one|[Tt]rue/,
9638
- variable: /\b\w+\b/,
9639
- punctuation: /[{}[\](),.:;]/
9640
- };
9641
- var pattern = /\{\{[\s\S]*?\}\}|\{%[\s\S]*?%\}|\{#[\s\S]*?#\}/g;
9642
- var markupTemplating = Prism.languages['markup-templating'];
9643
- Prism.hooks.add('before-tokenize', function (env) {
9644
- markupTemplating.buildPlaceholders(env, 'django', pattern);
9645
- });
9646
- Prism.hooks.add('after-tokenize', function (env) {
9647
- markupTemplating.tokenizePlaceholders(env, 'django');
9648
- }); // Add an Jinja2 alias
9649
- Prism.languages.jinja2 = Prism.languages.django;
9650
- Prism.hooks.add('before-tokenize', function (env) {
9651
- markupTemplating.buildPlaceholders(env, 'jinja2', pattern);
9652
- });
9653
- Prism.hooks.add('after-tokenize', function (env) {
9654
- markupTemplating.tokenizePlaceholders(env, 'jinja2');
9655
- });
9656
- })(Prism);
9657
- }
9607
+ var django_1;
9608
+ var hasRequiredDjango;
9658
9609
 
9659
- var dnsZoneFile_1 = dnsZoneFile;
9660
- dnsZoneFile.displayName = 'dnsZoneFile';
9661
- dnsZoneFile.aliases = [];
9662
- function dnsZoneFile(Prism) {
9663
- Prism.languages['dns-zone-file'] = {
9664
- comment: /;.*/,
9665
- string: {
9666
- pattern: /"(?:\\.|[^"\\\r\n])*"/,
9667
- greedy: true
9668
- },
9669
- variable: [
9670
- {
9671
- pattern: /(^\$ORIGIN[ \t]+)\S+/m,
9672
- lookbehind: true
9673
- },
9674
- {
9675
- pattern: /(^|\s)@(?=\s|$)/,
9676
- lookbehind: true
9677
- }
9678
- ],
9679
- keyword: /^\$(?:INCLUDE|ORIGIN|TTL)(?=\s|$)/m,
9680
- class: {
9681
- // https://tools.ietf.org/html/rfc1035#page-13
9682
- pattern: /(^|\s)(?:CH|CS|HS|IN)(?=\s|$)/,
9683
- lookbehind: true,
9684
- alias: 'keyword'
9685
- },
9686
- type: {
9687
- // https://en.wikipedia.org/wiki/List_of_DNS_record_types
9610
+ function requireDjango () {
9611
+ if (hasRequiredDjango) return django_1;
9612
+ hasRequiredDjango = 1;
9613
+ var refractorMarkupTemplating = requireMarkupTemplating();
9614
+ django_1 = django;
9615
+ django.displayName = 'django';
9616
+ django.aliases = ['jinja2'];
9617
+ function django(Prism) {
9618
+ Prism.register(refractorMarkupTemplating)
9619
+ // Django/Jinja2 syntax definition for Prism.js <http://prismjs.com> syntax highlighter.
9620
+ // Mostly it works OK but can paint code incorrectly on complex html/template tag combinations.
9621
+ ;(function (Prism) {
9622
+ Prism.languages.django = {
9623
+ comment: /^\{#[\s\S]*?#\}$/,
9624
+ tag: {
9625
+ pattern: /(^\{%[+-]?\s*)\w+/,
9626
+ lookbehind: true,
9627
+ alias: 'keyword'
9628
+ },
9629
+ delimiter: {
9630
+ pattern: /^\{[{%][+-]?|[+-]?[}%]\}$/,
9631
+ alias: 'punctuation'
9632
+ },
9633
+ string: {
9634
+ pattern: /("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,
9635
+ greedy: true
9636
+ },
9637
+ filter: {
9638
+ pattern: /(\|)\w+/,
9639
+ lookbehind: true,
9640
+ alias: 'function'
9641
+ },
9642
+ test: {
9643
+ pattern: /(\bis\s+(?:not\s+)?)(?!not\b)\w+/,
9644
+ lookbehind: true,
9645
+ alias: 'function'
9646
+ },
9647
+ function: /\b[a-z_]\w+(?=\s*\()/i,
9648
+ keyword:
9649
+ /\b(?:and|as|by|else|for|if|import|in|is|loop|not|or|recursive|with|without)\b/,
9650
+ operator: /[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,
9651
+ number: /\b\d+(?:\.\d+)?\b/,
9652
+ boolean: /[Ff]alse|[Nn]one|[Tt]rue/,
9653
+ variable: /\b\w+\b/,
9654
+ punctuation: /[{}[\](),.:;]/
9655
+ };
9656
+ var pattern = /\{\{[\s\S]*?\}\}|\{%[\s\S]*?%\}|\{#[\s\S]*?#\}/g;
9657
+ var markupTemplating = Prism.languages['markup-templating'];
9658
+ Prism.hooks.add('before-tokenize', function (env) {
9659
+ markupTemplating.buildPlaceholders(env, 'django', pattern);
9660
+ });
9661
+ Prism.hooks.add('after-tokenize', function (env) {
9662
+ markupTemplating.tokenizePlaceholders(env, 'django');
9663
+ }); // Add an Jinja2 alias
9664
+ Prism.languages.jinja2 = Prism.languages.django;
9665
+ Prism.hooks.add('before-tokenize', function (env) {
9666
+ markupTemplating.buildPlaceholders(env, 'jinja2', pattern);
9667
+ });
9668
+ Prism.hooks.add('after-tokenize', function (env) {
9669
+ markupTemplating.tokenizePlaceholders(env, 'jinja2');
9670
+ });
9671
+ })(Prism);
9672
+ }
9673
+ return django_1;
9674
+ }
9675
+
9676
+ var dnsZoneFile_1 = dnsZoneFile;
9677
+ dnsZoneFile.displayName = 'dnsZoneFile';
9678
+ dnsZoneFile.aliases = [];
9679
+ function dnsZoneFile(Prism) {
9680
+ Prism.languages['dns-zone-file'] = {
9681
+ comment: /;.*/,
9682
+ string: {
9683
+ pattern: /"(?:\\.|[^"\\\r\n])*"/,
9684
+ greedy: true
9685
+ },
9686
+ variable: [
9687
+ {
9688
+ pattern: /(^\$ORIGIN[ \t]+)\S+/m,
9689
+ lookbehind: true
9690
+ },
9691
+ {
9692
+ pattern: /(^|\s)@(?=\s|$)/,
9693
+ lookbehind: true
9694
+ }
9695
+ ],
9696
+ keyword: /^\$(?:INCLUDE|ORIGIN|TTL)(?=\s|$)/m,
9697
+ class: {
9698
+ // https://tools.ietf.org/html/rfc1035#page-13
9699
+ pattern: /(^|\s)(?:CH|CS|HS|IN)(?=\s|$)/,
9700
+ lookbehind: true,
9701
+ alias: 'keyword'
9702
+ },
9703
+ type: {
9704
+ // https://en.wikipedia.org/wiki/List_of_DNS_record_types
9688
9705
  pattern:
9689
9706
  /(^|\s)(?:A|A6|AAAA|AFSDB|APL|ATMA|CAA|CDNSKEY|CDS|CERT|CNAME|DHCID|DLV|DNAME|DNSKEY|DS|EID|GID|GPOS|HINFO|HIP|IPSECKEY|ISDN|KEY|KX|LOC|MAILA|MAILB|MB|MD|MF|MG|MINFO|MR|MX|NAPTR|NB|NBSTAT|NIMLOC|NINFO|NS|NSAP|NSAP-PTR|NSEC|NSEC3|NSEC3PARAM|NULL|NXT|OPENPGPKEY|PTR|PX|RKEY|RP|RRSIG|RT|SIG|SINK|SMIMEA|SOA|SPF|SRV|SSHFP|TA|TKEY|TLSA|TSIG|TXT|UID|UINFO|UNSPEC|URI|WKS|X25)(?=\s|$)/,
9690
9707
  lookbehind: true,
@@ -9817,96 +9834,87 @@ function docker(Prism) {
9817
9834
  })(Prism);
9818
9835
  }
9819
9836
 
9820
- var dot_1;
9821
- var hasRequiredDot;
9822
-
9823
- function requireDot () {
9824
- if (hasRequiredDot) return dot_1;
9825
- hasRequiredDot = 1;
9826
-
9827
- dot_1 = dot;
9828
- dot.displayName = 'dot';
9829
- dot.aliases = ['gv'];
9830
- function dot(Prism) {
9837
+ var dot_1 = dot;
9838
+ dot.displayName = 'dot';
9839
+ dot.aliases = ['gv'];
9840
+ function dot(Prism) {
9831
9841
  (function (Prism) {
9832
- var ID =
9833
- '(?:' +
9834
- [
9835
- // an identifier
9836
- /[a-zA-Z_\x80-\uFFFF][\w\x80-\uFFFF]*/.source, // a number
9837
- /-?(?:\.\d+|\d+(?:\.\d*)?)/.source, // a double-quoted string
9838
- /"[^"\\]*(?:\\[\s\S][^"\\]*)*"/.source, // HTML-like string
9839
- /<(?:[^<>]|(?!<!--)<(?:[^<>"']|"[^"]*"|'[^']*')+>|<!--(?:[^-]|-(?!->))*-->)*>/
9840
- .source
9841
- ].join('|') +
9842
- ')';
9843
- var IDInside = {
9844
- markup: {
9845
- pattern: /(^<)[\s\S]+(?=>$)/,
9846
- lookbehind: true,
9847
- alias: ['language-markup', 'language-html', 'language-xml'],
9848
- inside: Prism.languages.markup
9849
- }
9850
- };
9851
- /**
9852
- * @param {string} source
9853
- * @param {string} flags
9854
- * @returns {RegExp}
9855
- */
9856
- function withID(source, flags) {
9857
- return RegExp(
9858
- source.replace(/<ID>/g, function () {
9859
- return ID
9860
- }),
9861
- flags
9862
- )
9863
- }
9864
- Prism.languages.dot = {
9865
- comment: {
9866
- pattern: /\/\/.*|\/\*[\s\S]*?\*\/|^#.*/m,
9867
- greedy: true
9868
- },
9869
- 'graph-name': {
9870
- pattern: withID(
9871
- /(\b(?:digraph|graph|subgraph)[ \t\r\n]+)<ID>/.source,
9872
- 'i'
9873
- ),
9874
- lookbehind: true,
9875
- greedy: true,
9876
- alias: 'class-name',
9877
- inside: IDInside
9878
- },
9879
- 'attr-value': {
9880
- pattern: withID(/(=[ \t\r\n]*)<ID>/.source),
9881
- lookbehind: true,
9882
- greedy: true,
9883
- inside: IDInside
9884
- },
9885
- 'attr-name': {
9886
- pattern: withID(/([\[;, \t\r\n])<ID>(?=[ \t\r\n]*=)/.source),
9887
- lookbehind: true,
9888
- greedy: true,
9889
- inside: IDInside
9890
- },
9891
- keyword: /\b(?:digraph|edge|graph|node|strict|subgraph)\b/i,
9892
- 'compass-point': {
9893
- pattern: /(:[ \t\r\n]*)(?:[ewc_]|[ns][ew]?)(?![\w\x80-\uFFFF])/,
9894
- lookbehind: true,
9895
- alias: 'builtin'
9896
- },
9897
- node: {
9898
- pattern: withID(/(^|[^-.\w\x80-\uFFFF\\])<ID>/.source),
9899
- lookbehind: true,
9900
- greedy: true,
9901
- inside: IDInside
9902
- },
9903
- operator: /[=:]|-[->]/,
9904
- punctuation: /[\[\]{};,]/
9905
- };
9906
- Prism.languages.gv = Prism.languages.dot;
9907
- })(Prism);
9908
- }
9909
- return dot_1;
9842
+ var ID =
9843
+ '(?:' +
9844
+ [
9845
+ // an identifier
9846
+ /[a-zA-Z_\x80-\uFFFF][\w\x80-\uFFFF]*/.source, // a number
9847
+ /-?(?:\.\d+|\d+(?:\.\d*)?)/.source, // a double-quoted string
9848
+ /"[^"\\]*(?:\\[\s\S][^"\\]*)*"/.source, // HTML-like string
9849
+ /<(?:[^<>]|(?!<!--)<(?:[^<>"']|"[^"]*"|'[^']*')+>|<!--(?:[^-]|-(?!->))*-->)*>/
9850
+ .source
9851
+ ].join('|') +
9852
+ ')';
9853
+ var IDInside = {
9854
+ markup: {
9855
+ pattern: /(^<)[\s\S]+(?=>$)/,
9856
+ lookbehind: true,
9857
+ alias: ['language-markup', 'language-html', 'language-xml'],
9858
+ inside: Prism.languages.markup
9859
+ }
9860
+ };
9861
+ /**
9862
+ * @param {string} source
9863
+ * @param {string} flags
9864
+ * @returns {RegExp}
9865
+ */
9866
+ function withID(source, flags) {
9867
+ return RegExp(
9868
+ source.replace(/<ID>/g, function () {
9869
+ return ID
9870
+ }),
9871
+ flags
9872
+ )
9873
+ }
9874
+ Prism.languages.dot = {
9875
+ comment: {
9876
+ pattern: /\/\/.*|\/\*[\s\S]*?\*\/|^#.*/m,
9877
+ greedy: true
9878
+ },
9879
+ 'graph-name': {
9880
+ pattern: withID(
9881
+ /(\b(?:digraph|graph|subgraph)[ \t\r\n]+)<ID>/.source,
9882
+ 'i'
9883
+ ),
9884
+ lookbehind: true,
9885
+ greedy: true,
9886
+ alias: 'class-name',
9887
+ inside: IDInside
9888
+ },
9889
+ 'attr-value': {
9890
+ pattern: withID(/(=[ \t\r\n]*)<ID>/.source),
9891
+ lookbehind: true,
9892
+ greedy: true,
9893
+ inside: IDInside
9894
+ },
9895
+ 'attr-name': {
9896
+ pattern: withID(/([\[;, \t\r\n])<ID>(?=[ \t\r\n]*=)/.source),
9897
+ lookbehind: true,
9898
+ greedy: true,
9899
+ inside: IDInside
9900
+ },
9901
+ keyword: /\b(?:digraph|edge|graph|node|strict|subgraph)\b/i,
9902
+ 'compass-point': {
9903
+ pattern: /(:[ \t\r\n]*)(?:[ewc_]|[ns][ew]?)(?![\w\x80-\uFFFF])/,
9904
+ lookbehind: true,
9905
+ alias: 'builtin'
9906
+ },
9907
+ node: {
9908
+ pattern: withID(/(^|[^-.\w\x80-\uFFFF\\])<ID>/.source),
9909
+ lookbehind: true,
9910
+ greedy: true,
9911
+ inside: IDInside
9912
+ },
9913
+ operator: /[=:]|-[->]/,
9914
+ punctuation: /[\[\]{};,]/
9915
+ };
9916
+ Prism.languages.gv = Prism.languages.dot;
9917
+ })(Prism);
9910
9918
  }
9911
9919
 
9912
9920
  var ebnf_1;
@@ -9977,1632 +9985,1764 @@ function editorconfig(Prism) {
9977
9985
  };
9978
9986
  }
9979
9987
 
9980
- var eiffel_1 = eiffel;
9981
- eiffel.displayName = 'eiffel';
9982
- eiffel.aliases = [];
9983
- function eiffel(Prism) {
9984
- Prism.languages.eiffel = {
9985
- comment: /--.*/,
9986
- string: [
9987
- // Aligned-verbatim-strings
9988
- {
9989
- pattern: /"([^[]*)\[[\s\S]*?\]\1"/,
9990
- greedy: true
9991
- }, // Non-aligned-verbatim-strings
9992
- {
9993
- pattern: /"([^{]*)\{[\s\S]*?\}\1"/,
9994
- greedy: true
9995
- }, // Single-line string
9996
- {
9997
- pattern: /"(?:%(?:(?!\n)\s)*\n\s*%|%\S|[^%"\r\n])*"/,
9998
- greedy: true
9999
- }
10000
- ],
10001
- // normal char | special char | char code
10002
- char: /'(?:%.|[^%'\r\n])+'/,
10003
- keyword:
10004
- /\b(?:across|agent|alias|all|and|as|assign|attached|attribute|check|class|convert|create|Current|debug|deferred|detachable|do|else|elseif|end|ensure|expanded|export|external|feature|from|frozen|if|implies|inherit|inspect|invariant|like|local|loop|not|note|obsolete|old|once|or|Precursor|redefine|rename|require|rescue|Result|retry|select|separate|some|then|undefine|until|variant|Void|when|xor)\b/i,
10005
- boolean: /\b(?:False|True)\b/i,
10006
- // Convention: class-names are always all upper-case characters
10007
- 'class-name': /\b[A-Z][\dA-Z_]*\b/,
10008
- number: [
10009
- // hexa | octal | bin
10010
- /\b0[xcb][\da-f](?:_*[\da-f])*\b/i, // Decimal
10011
- /(?:\b\d(?:_*\d)*)?\.(?:(?:\d(?:_*\d)*)?e[+-]?)?\d(?:_*\d)*\b|\b\d(?:_*\d)*\b\.?/i
10012
- ],
10013
- punctuation: /:=|<<|>>|\(\||\|\)|->|\.(?=\w)|[{}[\];(),:?]/,
10014
- operator: /\\\\|\|\.\.\||\.\.|\/[~\/=]?|[><]=?|[-+*^=~]/
10015
- };
10016
- }
9988
+ var eiffel_1;
9989
+ var hasRequiredEiffel;
10017
9990
 
10018
- var refractorMarkupTemplating$2 = requireMarkupTemplating();
10019
- var ejs_1 = ejs;
10020
- ejs.displayName = 'ejs';
10021
- ejs.aliases = ['eta'];
10022
- function ejs(Prism) {
10023
- Prism.register(refractorMarkupTemplating$2)
10024
- ;(function (Prism) {
10025
- Prism.languages.ejs = {
10026
- delimiter: {
10027
- pattern: /^<%[-_=]?|[-_]?%>$/,
10028
- alias: 'punctuation'
10029
- },
10030
- comment: /^#[\s\S]*/,
10031
- 'language-javascript': {
10032
- pattern: /[\s\S]+/,
10033
- inside: Prism.languages.javascript
10034
- }
10035
- };
10036
- Prism.hooks.add('before-tokenize', function (env) {
10037
- var ejsPattern = /<%(?!%)[\s\S]+?%>/g;
10038
- Prism.languages['markup-templating'].buildPlaceholders(
10039
- env,
10040
- 'ejs',
10041
- ejsPattern
10042
- );
10043
- });
10044
- Prism.hooks.add('after-tokenize', function (env) {
10045
- Prism.languages['markup-templating'].tokenizePlaceholders(env, 'ejs');
10046
- });
10047
- Prism.languages.eta = Prism.languages.ejs;
10048
- })(Prism);
10049
- }
9991
+ function requireEiffel () {
9992
+ if (hasRequiredEiffel) return eiffel_1;
9993
+ hasRequiredEiffel = 1;
10050
9994
 
10051
- var elixir_1 = elixir;
10052
- elixir.displayName = 'elixir';
10053
- elixir.aliases = [];
10054
- function elixir(Prism) {
10055
- Prism.languages.elixir = {
10056
- doc: {
10057
- pattern:
10058
- /@(?:doc|moduledoc)\s+(?:("""|''')[\s\S]*?\1|("|')(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2)/,
10059
- inside: {
10060
- attribute: /^@\w+/,
10061
- string: /['"][\s\S]+/
10062
- }
10063
- },
10064
- comment: {
10065
- pattern: /#.*/,
10066
- greedy: true
10067
- },
10068
- // ~r"""foo""" (multi-line), ~r'''foo''' (multi-line), ~r/foo/, ~r|foo|, ~r"foo", ~r'foo', ~r(foo), ~r[foo], ~r{foo}, ~r<foo>
10069
- regex: {
10070
- pattern:
10071
- /~[rR](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|[^\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[uismxfr]*/,
10072
- greedy: true
10073
- },
10074
- string: [
10075
- {
10076
- // ~s"""foo""" (multi-line), ~s'''foo''' (multi-line), ~s/foo/, ~s|foo|, ~s"foo", ~s'foo', ~s(foo), ~s[foo], ~s{foo} (with interpolation care), ~s<foo>
10077
- pattern:
10078
- /~[cCsSwW](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|#\{[^}]+\}|#(?!\{)|[^#\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[csa]?/,
10079
- greedy: true,
10080
- inside: {
10081
- // See interpolation below
10082
- }
10083
- },
10084
- {
10085
- pattern: /("""|''')[\s\S]*?\1/,
10086
- greedy: true,
10087
- inside: {
10088
- // See interpolation below
10089
- }
10090
- },
10091
- {
10092
- // Multi-line strings are allowed
10093
- pattern: /("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,
10094
- greedy: true,
10095
- inside: {
10096
- // See interpolation below
10097
- }
10098
- }
10099
- ],
10100
- atom: {
10101
- // Look-behind prevents bad highlighting of the :: operator
10102
- pattern: /(^|[^:]):\w+/,
10103
- lookbehind: true,
10104
- alias: 'symbol'
10105
- },
10106
- module: {
10107
- pattern: /\b[A-Z]\w*\b/,
10108
- alias: 'class-name'
10109
- },
10110
- // Look-ahead prevents bad highlighting of the :: operator
10111
- 'attr-name': /\b\w+\??:(?!:)/,
10112
- argument: {
10113
- // Look-behind prevents bad highlighting of the && operator
10114
- pattern: /(^|[^&])&\d+/,
10115
- lookbehind: true,
10116
- alias: 'variable'
10117
- },
10118
- attribute: {
10119
- pattern: /@\w+/,
10120
- alias: 'variable'
10121
- },
10122
- function: /\b[_a-zA-Z]\w*[?!]?(?:(?=\s*(?:\.\s*)?\()|(?=\/\d))/,
10123
- number: /\b(?:0[box][a-f\d_]+|\d[\d_]*)(?:\.[\d_]+)?(?:e[+-]?[\d_]+)?\b/i,
10124
- keyword:
10125
- /\b(?:after|alias|and|case|catch|cond|def(?:callback|delegate|exception|impl|macro|module|n|np|p|protocol|struct)?|do|else|end|fn|for|if|import|not|or|quote|raise|require|rescue|try|unless|unquote|use|when)\b/,
10126
- boolean: /\b(?:false|nil|true)\b/,
10127
- operator: [
10128
- /\bin\b|&&?|\|[|>]?|\\\\|::|\.\.\.?|\+\+?|-[->]?|<[-=>]|>=|!==?|\B!|=(?:==?|[>~])?|[*\/^]/,
10129
- {
10130
- // We don't want to match <<
10131
- pattern: /([^<])<(?!<)/,
10132
- lookbehind: true
10133
- },
10134
- {
10135
- // We don't want to match >>
10136
- pattern: /([^>])>(?!>)/,
10137
- lookbehind: true
10138
- }
10139
- ],
10140
- punctuation: /<<|>>|[.,%\[\]{}()]/
10141
- };
10142
- Prism.languages.elixir.string.forEach(function (o) {
10143
- o.inside = {
10144
- interpolation: {
10145
- pattern: /#\{[^}]+\}/,
10146
- inside: {
10147
- delimiter: {
10148
- pattern: /^#\{|\}$/,
10149
- alias: 'punctuation'
10150
- },
10151
- rest: Prism.languages.elixir
10152
- }
10153
- }
10154
- };
10155
- });
9995
+ eiffel_1 = eiffel;
9996
+ eiffel.displayName = 'eiffel';
9997
+ eiffel.aliases = [];
9998
+ function eiffel(Prism) {
9999
+ Prism.languages.eiffel = {
10000
+ comment: /--.*/,
10001
+ string: [
10002
+ // Aligned-verbatim-strings
10003
+ {
10004
+ pattern: /"([^[]*)\[[\s\S]*?\]\1"/,
10005
+ greedy: true
10006
+ }, // Non-aligned-verbatim-strings
10007
+ {
10008
+ pattern: /"([^{]*)\{[\s\S]*?\}\1"/,
10009
+ greedy: true
10010
+ }, // Single-line string
10011
+ {
10012
+ pattern: /"(?:%(?:(?!\n)\s)*\n\s*%|%\S|[^%"\r\n])*"/,
10013
+ greedy: true
10014
+ }
10015
+ ],
10016
+ // normal char | special char | char code
10017
+ char: /'(?:%.|[^%'\r\n])+'/,
10018
+ keyword:
10019
+ /\b(?:across|agent|alias|all|and|as|assign|attached|attribute|check|class|convert|create|Current|debug|deferred|detachable|do|else|elseif|end|ensure|expanded|export|external|feature|from|frozen|if|implies|inherit|inspect|invariant|like|local|loop|not|note|obsolete|old|once|or|Precursor|redefine|rename|require|rescue|Result|retry|select|separate|some|then|undefine|until|variant|Void|when|xor)\b/i,
10020
+ boolean: /\b(?:False|True)\b/i,
10021
+ // Convention: class-names are always all upper-case characters
10022
+ 'class-name': /\b[A-Z][\dA-Z_]*\b/,
10023
+ number: [
10024
+ // hexa | octal | bin
10025
+ /\b0[xcb][\da-f](?:_*[\da-f])*\b/i, // Decimal
10026
+ /(?:\b\d(?:_*\d)*)?\.(?:(?:\d(?:_*\d)*)?e[+-]?)?\d(?:_*\d)*\b|\b\d(?:_*\d)*\b\.?/i
10027
+ ],
10028
+ punctuation: /:=|<<|>>|\(\||\|\)|->|\.(?=\w)|[{}[\];(),:?]/,
10029
+ operator: /\\\\|\|\.\.\||\.\.|\/[~\/=]?|[><]=?|[-+*^=~]/
10030
+ };
10031
+ }
10032
+ return eiffel_1;
10156
10033
  }
10157
10034
 
10158
- var elm_1 = elm;
10159
- elm.displayName = 'elm';
10160
- elm.aliases = [];
10161
- function elm(Prism) {
10162
- Prism.languages.elm = {
10163
- comment: /--.*|\{-[\s\S]*?-\}/,
10164
- char: {
10165
- pattern:
10166
- /'(?:[^\\'\r\n]|\\(?:[abfnrtv\\']|\d+|x[0-9a-fA-F]+|u\{[0-9a-fA-F]+\}))'/,
10167
- greedy: true
10168
- },
10169
- string: [
10170
- {
10171
- // Multiline strings are wrapped in triple ". Quotes may appear unescaped.
10172
- pattern: /"""[\s\S]*?"""/,
10173
- greedy: true
10174
- },
10175
- {
10176
- pattern: /"(?:[^\\"\r\n]|\\.)*"/,
10177
- greedy: true
10178
- }
10179
- ],
10180
- 'import-statement': {
10181
- // The imported or hidden names are not included in this import
10182
- // statement. This is because we want to highlight those exactly like
10183
- // we do for the names in the program.
10184
- pattern:
10185
- /(^[\t ]*)import\s+[A-Z]\w*(?:\.[A-Z]\w*)*(?:\s+as\s+(?:[A-Z]\w*)(?:\.[A-Z]\w*)*)?(?:\s+exposing\s+)?/m,
10186
- lookbehind: true,
10187
- inside: {
10188
- keyword: /\b(?:as|exposing|import)\b/
10189
- }
10190
- },
10191
- keyword:
10192
- /\b(?:alias|as|case|else|exposing|if|in|infixl|infixr|let|module|of|then|type)\b/,
10193
- // These are builtin variables only. Constructors are highlighted later as a constant.
10194
- builtin:
10195
- /\b(?:abs|acos|always|asin|atan|atan2|ceiling|clamp|compare|cos|curry|degrees|e|flip|floor|fromPolar|identity|isInfinite|isNaN|logBase|max|min|negate|never|not|pi|radians|rem|round|sin|sqrt|tan|toFloat|toPolar|toString|truncate|turns|uncurry|xor)\b/,
10196
- // decimal integers and floating point numbers | hexadecimal integers
10197
- number: /\b(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?|0x[0-9a-f]+)\b/i,
10198
- // Most of this is needed because of the meaning of a single '.'.
10199
- // If it stands alone freely, it is the function composition.
10200
- // It may also be a separator between a module name and an identifier => no
10201
- // operator. If it comes together with other special characters it is an
10202
- // operator too.
10203
- // Valid operator characters in 0.18: +-/*=.$<>:&|^?%#@~!
10204
- // Ref: https://groups.google.com/forum/#!msg/elm-dev/0AHSnDdkSkQ/E0SVU70JEQAJ
10205
- operator: /\s\.\s|[+\-/*=.$<>:&|^?%#@~!]{2,}|[+\-/*=$<>:&|^?%#@~!]/,
10206
- // In Elm, nearly everything is a variable, do not highlight these.
10207
- hvariable: /\b(?:[A-Z]\w*\.)*[a-z]\w*\b/,
10208
- constant: /\b(?:[A-Z]\w*\.)*[A-Z]\w*\b/,
10209
- punctuation: /[{}[\]|(),.:]/
10210
- };
10211
- }
10035
+ var ejs_1;
10036
+ var hasRequiredEjs;
10212
10037
 
10213
- var refractorRuby = ruby_1;
10214
- var refractorMarkupTemplating$1 = requireMarkupTemplating();
10215
- var erb_1 = erb;
10216
- erb.displayName = 'erb';
10217
- erb.aliases = [];
10218
- function erb(Prism) {
10219
- Prism.register(refractorRuby);
10220
- Prism.register(refractorMarkupTemplating$1)
10221
- ;(function (Prism) {
10222
- Prism.languages.erb = {
10223
- delimiter: {
10224
- pattern: /^(\s*)<%=?|%>(?=\s*$)/,
10225
- lookbehind: true,
10226
- alias: 'punctuation'
10227
- },
10228
- ruby: {
10229
- pattern: /\s*\S[\s\S]*/,
10230
- alias: 'language-ruby',
10231
- inside: Prism.languages.ruby
10232
- }
10233
- };
10234
- Prism.hooks.add('before-tokenize', function (env) {
10235
- var erbPattern =
10236
- /<%=?(?:[^\r\n]|[\r\n](?!=begin)|[\r\n]=begin\s(?:[^\r\n]|[\r\n](?!=end))*[\r\n]=end)+?%>/g;
10237
- Prism.languages['markup-templating'].buildPlaceholders(
10238
- env,
10239
- 'erb',
10240
- erbPattern
10241
- );
10242
- });
10243
- Prism.hooks.add('after-tokenize', function (env) {
10244
- Prism.languages['markup-templating'].tokenizePlaceholders(env, 'erb');
10245
- });
10246
- })(Prism);
10038
+ function requireEjs () {
10039
+ if (hasRequiredEjs) return ejs_1;
10040
+ hasRequiredEjs = 1;
10041
+ var refractorMarkupTemplating = requireMarkupTemplating();
10042
+ ejs_1 = ejs;
10043
+ ejs.displayName = 'ejs';
10044
+ ejs.aliases = ['eta'];
10045
+ function ejs(Prism) {
10046
+ Prism.register(refractorMarkupTemplating)
10047
+ ;(function (Prism) {
10048
+ Prism.languages.ejs = {
10049
+ delimiter: {
10050
+ pattern: /^<%[-_=]?|[-_]?%>$/,
10051
+ alias: 'punctuation'
10052
+ },
10053
+ comment: /^#[\s\S]*/,
10054
+ 'language-javascript': {
10055
+ pattern: /[\s\S]+/,
10056
+ inside: Prism.languages.javascript
10057
+ }
10058
+ };
10059
+ Prism.hooks.add('before-tokenize', function (env) {
10060
+ var ejsPattern = /<%(?!%)[\s\S]+?%>/g;
10061
+ Prism.languages['markup-templating'].buildPlaceholders(
10062
+ env,
10063
+ 'ejs',
10064
+ ejsPattern
10065
+ );
10066
+ });
10067
+ Prism.hooks.add('after-tokenize', function (env) {
10068
+ Prism.languages['markup-templating'].tokenizePlaceholders(env, 'ejs');
10069
+ });
10070
+ Prism.languages.eta = Prism.languages.ejs;
10071
+ })(Prism);
10072
+ }
10073
+ return ejs_1;
10247
10074
  }
10248
10075
 
10249
- var erlang_1 = erlang;
10250
- erlang.displayName = 'erlang';
10251
- erlang.aliases = [];
10252
- function erlang(Prism) {
10253
- Prism.languages.erlang = {
10254
- comment: /%.+/,
10255
- string: {
10256
- pattern: /"(?:\\.|[^\\"\r\n])*"/,
10257
- greedy: true
10258
- },
10259
- 'quoted-function': {
10260
- pattern: /'(?:\\.|[^\\'\r\n])+'(?=\()/,
10261
- alias: 'function'
10262
- },
10263
- 'quoted-atom': {
10264
- pattern: /'(?:\\.|[^\\'\r\n])+'/,
10265
- alias: 'atom'
10266
- },
10267
- boolean: /\b(?:false|true)\b/,
10268
- keyword: /\b(?:after|case|catch|end|fun|if|of|receive|try|when)\b/,
10269
- number: [
10270
- /\$\\?./,
10271
- /\b\d+#[a-z0-9]+/i,
10272
- /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i
10273
- ],
10274
- function: /\b[a-z][\w@]*(?=\()/,
10275
- variable: {
10276
- // Look-behind is used to prevent wrong highlighting of atoms containing "@"
10277
- pattern: /(^|[^@])(?:\b|\?)[A-Z_][\w@]*/,
10278
- lookbehind: true
10279
- },
10280
- operator: [
10281
- /[=\/<>:]=|=[:\/]=|\+\+?|--?|[=*\/!]|\b(?:and|andalso|band|bnot|bor|bsl|bsr|bxor|div|not|or|orelse|rem|xor)\b/,
10282
- {
10283
- // We don't want to match <<
10284
- pattern: /(^|[^<])<(?!<)/,
10285
- lookbehind: true
10286
- },
10287
- {
10288
- // We don't want to match >>
10289
- pattern: /(^|[^>])>(?!>)/,
10290
- lookbehind: true
10291
- }
10292
- ],
10293
- atom: /\b[a-z][\w@]*/,
10294
- punctuation: /[()[\]{}:;,.#|]|<<|>>/
10295
- };
10296
- }
10076
+ var elixir_1;
10077
+ var hasRequiredElixir;
10297
10078
 
10298
- var lua_1 = lua;
10299
- lua.displayName = 'lua';
10300
- lua.aliases = [];
10301
- function lua(Prism) {
10302
- Prism.languages.lua = {
10303
- comment: /^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,
10304
- // \z may be used to skip the following space
10305
- string: {
10306
- pattern:
10307
- /(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,
10308
- greedy: true
10309
- },
10310
- number:
10311
- /\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,
10312
- keyword:
10313
- /\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,
10314
- function: /(?!\d)\w+(?=\s*(?:[({]))/,
10315
- operator: [
10316
- /[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,
10317
- {
10318
- // Match ".." but don't break "..."
10319
- pattern: /(^|[^.])\.\.(?!\.)/,
10320
- lookbehind: true
10321
- }
10322
- ],
10323
- punctuation: /[\[\](){},;]|\.+|:+/
10324
- };
10079
+ function requireElixir () {
10080
+ if (hasRequiredElixir) return elixir_1;
10081
+ hasRequiredElixir = 1;
10082
+
10083
+ elixir_1 = elixir;
10084
+ elixir.displayName = 'elixir';
10085
+ elixir.aliases = [];
10086
+ function elixir(Prism) {
10087
+ Prism.languages.elixir = {
10088
+ doc: {
10089
+ pattern:
10090
+ /@(?:doc|moduledoc)\s+(?:("""|''')[\s\S]*?\1|("|')(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2)/,
10091
+ inside: {
10092
+ attribute: /^@\w+/,
10093
+ string: /['"][\s\S]+/
10094
+ }
10095
+ },
10096
+ comment: {
10097
+ pattern: /#.*/,
10098
+ greedy: true
10099
+ },
10100
+ // ~r"""foo""" (multi-line), ~r'''foo''' (multi-line), ~r/foo/, ~r|foo|, ~r"foo", ~r'foo', ~r(foo), ~r[foo], ~r{foo}, ~r<foo>
10101
+ regex: {
10102
+ pattern:
10103
+ /~[rR](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|[^\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[uismxfr]*/,
10104
+ greedy: true
10105
+ },
10106
+ string: [
10107
+ {
10108
+ // ~s"""foo""" (multi-line), ~s'''foo''' (multi-line), ~s/foo/, ~s|foo|, ~s"foo", ~s'foo', ~s(foo), ~s[foo], ~s{foo} (with interpolation care), ~s<foo>
10109
+ pattern:
10110
+ /~[cCsSwW](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|#\{[^}]+\}|#(?!\{)|[^#\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[csa]?/,
10111
+ greedy: true,
10112
+ inside: {
10113
+ // See interpolation below
10114
+ }
10115
+ },
10116
+ {
10117
+ pattern: /("""|''')[\s\S]*?\1/,
10118
+ greedy: true,
10119
+ inside: {
10120
+ // See interpolation below
10121
+ }
10122
+ },
10123
+ {
10124
+ // Multi-line strings are allowed
10125
+ pattern: /("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,
10126
+ greedy: true,
10127
+ inside: {
10128
+ // See interpolation below
10129
+ }
10130
+ }
10131
+ ],
10132
+ atom: {
10133
+ // Look-behind prevents bad highlighting of the :: operator
10134
+ pattern: /(^|[^:]):\w+/,
10135
+ lookbehind: true,
10136
+ alias: 'symbol'
10137
+ },
10138
+ module: {
10139
+ pattern: /\b[A-Z]\w*\b/,
10140
+ alias: 'class-name'
10141
+ },
10142
+ // Look-ahead prevents bad highlighting of the :: operator
10143
+ 'attr-name': /\b\w+\??:(?!:)/,
10144
+ argument: {
10145
+ // Look-behind prevents bad highlighting of the && operator
10146
+ pattern: /(^|[^&])&\d+/,
10147
+ lookbehind: true,
10148
+ alias: 'variable'
10149
+ },
10150
+ attribute: {
10151
+ pattern: /@\w+/,
10152
+ alias: 'variable'
10153
+ },
10154
+ function: /\b[_a-zA-Z]\w*[?!]?(?:(?=\s*(?:\.\s*)?\()|(?=\/\d))/,
10155
+ number: /\b(?:0[box][a-f\d_]+|\d[\d_]*)(?:\.[\d_]+)?(?:e[+-]?[\d_]+)?\b/i,
10156
+ keyword:
10157
+ /\b(?:after|alias|and|case|catch|cond|def(?:callback|delegate|exception|impl|macro|module|n|np|p|protocol|struct)?|do|else|end|fn|for|if|import|not|or|quote|raise|require|rescue|try|unless|unquote|use|when)\b/,
10158
+ boolean: /\b(?:false|nil|true)\b/,
10159
+ operator: [
10160
+ /\bin\b|&&?|\|[|>]?|\\\\|::|\.\.\.?|\+\+?|-[->]?|<[-=>]|>=|!==?|\B!|=(?:==?|[>~])?|[*\/^]/,
10161
+ {
10162
+ // We don't want to match <<
10163
+ pattern: /([^<])<(?!<)/,
10164
+ lookbehind: true
10165
+ },
10166
+ {
10167
+ // We don't want to match >>
10168
+ pattern: /([^>])>(?!>)/,
10169
+ lookbehind: true
10170
+ }
10171
+ ],
10172
+ punctuation: /<<|>>|[.,%\[\]{}()]/
10173
+ };
10174
+ Prism.languages.elixir.string.forEach(function (o) {
10175
+ o.inside = {
10176
+ interpolation: {
10177
+ pattern: /#\{[^}]+\}/,
10178
+ inside: {
10179
+ delimiter: {
10180
+ pattern: /^#\{|\}$/,
10181
+ alias: 'punctuation'
10182
+ },
10183
+ rest: Prism.languages.elixir
10184
+ }
10185
+ }
10186
+ };
10187
+ });
10188
+ }
10189
+ return elixir_1;
10325
10190
  }
10326
10191
 
10327
- var refractorLua = lua_1;
10328
- var refractorMarkupTemplating = requireMarkupTemplating();
10329
- var etlua_1 = etlua;
10330
- etlua.displayName = 'etlua';
10331
- etlua.aliases = [];
10332
- function etlua(Prism) {
10333
- Prism.register(refractorLua);
10334
- Prism.register(refractorMarkupTemplating)
10335
- ;(function (Prism) {
10336
- Prism.languages.etlua = {
10337
- delimiter: {
10338
- pattern: /^<%[-=]?|-?%>$/,
10339
- alias: 'punctuation'
10340
- },
10341
- 'language-lua': {
10342
- pattern: /[\s\S]+/,
10343
- inside: Prism.languages.lua
10344
- }
10345
- };
10346
- Prism.hooks.add('before-tokenize', function (env) {
10347
- var pattern = /<%[\s\S]+?%>/g;
10348
- Prism.languages['markup-templating'].buildPlaceholders(
10349
- env,
10350
- 'etlua',
10351
- pattern
10352
- );
10353
- });
10354
- Prism.hooks.add('after-tokenize', function (env) {
10355
- Prism.languages['markup-templating'].tokenizePlaceholders(env, 'etlua');
10356
- });
10357
- })(Prism);
10192
+ var elm_1;
10193
+ var hasRequiredElm;
10194
+
10195
+ function requireElm () {
10196
+ if (hasRequiredElm) return elm_1;
10197
+ hasRequiredElm = 1;
10198
+
10199
+ elm_1 = elm;
10200
+ elm.displayName = 'elm';
10201
+ elm.aliases = [];
10202
+ function elm(Prism) {
10203
+ Prism.languages.elm = {
10204
+ comment: /--.*|\{-[\s\S]*?-\}/,
10205
+ char: {
10206
+ pattern:
10207
+ /'(?:[^\\'\r\n]|\\(?:[abfnrtv\\']|\d+|x[0-9a-fA-F]+|u\{[0-9a-fA-F]+\}))'/,
10208
+ greedy: true
10209
+ },
10210
+ string: [
10211
+ {
10212
+ // Multiline strings are wrapped in triple ". Quotes may appear unescaped.
10213
+ pattern: /"""[\s\S]*?"""/,
10214
+ greedy: true
10215
+ },
10216
+ {
10217
+ pattern: /"(?:[^\\"\r\n]|\\.)*"/,
10218
+ greedy: true
10219
+ }
10220
+ ],
10221
+ 'import-statement': {
10222
+ // The imported or hidden names are not included in this import
10223
+ // statement. This is because we want to highlight those exactly like
10224
+ // we do for the names in the program.
10225
+ pattern:
10226
+ /(^[\t ]*)import\s+[A-Z]\w*(?:\.[A-Z]\w*)*(?:\s+as\s+(?:[A-Z]\w*)(?:\.[A-Z]\w*)*)?(?:\s+exposing\s+)?/m,
10227
+ lookbehind: true,
10228
+ inside: {
10229
+ keyword: /\b(?:as|exposing|import)\b/
10230
+ }
10231
+ },
10232
+ keyword:
10233
+ /\b(?:alias|as|case|else|exposing|if|in|infixl|infixr|let|module|of|then|type)\b/,
10234
+ // These are builtin variables only. Constructors are highlighted later as a constant.
10235
+ builtin:
10236
+ /\b(?:abs|acos|always|asin|atan|atan2|ceiling|clamp|compare|cos|curry|degrees|e|flip|floor|fromPolar|identity|isInfinite|isNaN|logBase|max|min|negate|never|not|pi|radians|rem|round|sin|sqrt|tan|toFloat|toPolar|toString|truncate|turns|uncurry|xor)\b/,
10237
+ // decimal integers and floating point numbers | hexadecimal integers
10238
+ number: /\b(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?|0x[0-9a-f]+)\b/i,
10239
+ // Most of this is needed because of the meaning of a single '.'.
10240
+ // If it stands alone freely, it is the function composition.
10241
+ // It may also be a separator between a module name and an identifier => no
10242
+ // operator. If it comes together with other special characters it is an
10243
+ // operator too.
10244
+ // Valid operator characters in 0.18: +-/*=.$<>:&|^?%#@~!
10245
+ // Ref: https://groups.google.com/forum/#!msg/elm-dev/0AHSnDdkSkQ/E0SVU70JEQAJ
10246
+ operator: /\s\.\s|[+\-/*=.$<>:&|^?%#@~!]{2,}|[+\-/*=$<>:&|^?%#@~!]/,
10247
+ // In Elm, nearly everything is a variable, do not highlight these.
10248
+ hvariable: /\b(?:[A-Z]\w*\.)*[a-z]\w*\b/,
10249
+ constant: /\b(?:[A-Z]\w*\.)*[A-Z]\w*\b/,
10250
+ punctuation: /[{}[\]|(),.:]/
10251
+ };
10252
+ }
10253
+ return elm_1;
10358
10254
  }
10359
10255
 
10360
- var excelFormula_1 = excelFormula;
10361
- excelFormula.displayName = 'excelFormula';
10362
- excelFormula.aliases = [];
10363
- function excelFormula(Prism) {
10364
- Prism.languages['excel-formula'] = {
10365
- comment: {
10366
- pattern: /(\bN\(\s*)"(?:[^"]|"")*"(?=\s*\))/i,
10367
- lookbehind: true,
10368
- greedy: true
10369
- },
10370
- string: {
10371
- pattern: /"(?:[^"]|"")*"(?!")/,
10372
- greedy: true
10373
- },
10374
- reference: {
10375
- // https://www.ablebits.com/office-addins-blog/2015/12/08/excel-reference-another-sheet-workbook/
10376
- // Sales!B2
10377
- // 'Winter sales'!B2
10378
- // [Sales.xlsx]Jan!B2:B5
10379
- // D:\Reports\[Sales.xlsx]Jan!B2:B5
10380
- // '[Sales.xlsx]Jan sales'!B2:B5
10381
- // 'D:\Reports\[Sales.xlsx]Jan sales'!B2:B5
10382
- pattern:
10383
- /(?:'[^']*'|(?:[^\s()[\]{}<>*?"';,$&]*\[[^^\s()[\]{}<>*?"']+\])?\w+)!/,
10384
- greedy: true,
10385
- alias: 'string',
10386
- inside: {
10387
- operator: /!$/,
10388
- punctuation: /'/,
10389
- sheet: {
10390
- pattern: /[^[\]]+$/,
10391
- alias: 'function'
10392
- },
10393
- file: {
10394
- pattern: /\[[^[\]]+\]$/,
10395
- inside: {
10396
- punctuation: /[[\]]/
10397
- }
10398
- },
10399
- path: /[\s\S]+/
10400
- }
10401
- },
10402
- 'function-name': {
10403
- pattern: /\b[A-Z]\w*(?=\()/i,
10404
- alias: 'keyword'
10405
- },
10406
- range: {
10407
- pattern:
10408
- /\$?\b(?:[A-Z]+\$?\d+:\$?[A-Z]+\$?\d+|[A-Z]+:\$?[A-Z]+|\d+:\$?\d+)\b/i,
10409
- alias: 'property',
10410
- inside: {
10411
- operator: /:/,
10412
- cell: /\$?[A-Z]+\$?\d+/i,
10413
- column: /\$?[A-Z]+/i,
10414
- row: /\$?\d+/
10415
- }
10416
- },
10417
- cell: {
10418
- // Excel is case insensitive, so the string "foo1" could be either a variable or a cell.
10419
- // To combat this, we match cells case insensitive, if the contain at least one "$", and case sensitive otherwise.
10420
- pattern: /\b[A-Z]+\d+\b|\$[A-Za-z]+\$?\d+\b|\b[A-Za-z]+\$\d+\b/,
10421
- alias: 'property'
10422
- },
10423
- number: /(?:\b\d+(?:\.\d+)?|\B\.\d+)(?:e[+-]?\d+)?\b/i,
10424
- boolean: /\b(?:FALSE|TRUE)\b/i,
10425
- operator: /[-+*/^%=&,]|<[=>]?|>=?/,
10426
- punctuation: /[[\]();{}|]/
10427
- };
10428
- Prism.languages['xlsx'] = Prism.languages['xls'] =
10429
- Prism.languages['excel-formula'];
10256
+ var erb_1;
10257
+ var hasRequiredErb;
10258
+
10259
+ function requireErb () {
10260
+ if (hasRequiredErb) return erb_1;
10261
+ hasRequiredErb = 1;
10262
+ var refractorRuby = ruby_1;
10263
+ var refractorMarkupTemplating = requireMarkupTemplating();
10264
+ erb_1 = erb;
10265
+ erb.displayName = 'erb';
10266
+ erb.aliases = [];
10267
+ function erb(Prism) {
10268
+ Prism.register(refractorRuby);
10269
+ Prism.register(refractorMarkupTemplating)
10270
+ ;(function (Prism) {
10271
+ Prism.languages.erb = {
10272
+ delimiter: {
10273
+ pattern: /^(\s*)<%=?|%>(?=\s*$)/,
10274
+ lookbehind: true,
10275
+ alias: 'punctuation'
10276
+ },
10277
+ ruby: {
10278
+ pattern: /\s*\S[\s\S]*/,
10279
+ alias: 'language-ruby',
10280
+ inside: Prism.languages.ruby
10281
+ }
10282
+ };
10283
+ Prism.hooks.add('before-tokenize', function (env) {
10284
+ var erbPattern =
10285
+ /<%=?(?:[^\r\n]|[\r\n](?!=begin)|[\r\n]=begin\s(?:[^\r\n]|[\r\n](?!=end))*[\r\n]=end)+?%>/g;
10286
+ Prism.languages['markup-templating'].buildPlaceholders(
10287
+ env,
10288
+ 'erb',
10289
+ erbPattern
10290
+ );
10291
+ });
10292
+ Prism.hooks.add('after-tokenize', function (env) {
10293
+ Prism.languages['markup-templating'].tokenizePlaceholders(env, 'erb');
10294
+ });
10295
+ })(Prism);
10296
+ }
10297
+ return erb_1;
10430
10298
  }
10431
10299
 
10432
- var factor_1 = factor;
10433
- factor.displayName = 'factor';
10434
- factor.aliases = [];
10435
- function factor(Prism) {
10436
- (function (Prism) {
10437
- var comment_inside = {
10438
- function:
10439
- /\b(?:BUGS?|FIX(?:MES?)?|NOTES?|TODOS?|XX+|HACKS?|WARN(?:ING)?|\?{2,}|!{2,})\b/
10440
- };
10441
- var string_inside = {
10442
- number: /\\[^\s']|%\w/
10443
- };
10444
- var factor = {
10445
- comment: [
10446
- {
10447
- // ! single-line exclamation point comments with whitespace after/around the !
10448
- pattern: /(^|\s)(?:! .*|!$)/,
10449
- lookbehind: true,
10450
- inside: comment_inside
10451
- },
10452
- /* from basis/multiline: */
10453
- {
10454
- // /* comment */, /* comment*/
10455
- pattern: /(^|\s)\/\*\s[\s\S]*?\*\/(?=\s|$)/,
10456
- lookbehind: true,
10457
- greedy: true,
10458
- inside: comment_inside
10459
- },
10460
- {
10461
- // ![[ comment ]] , ![===[ comment]===]
10462
- pattern: /(^|\s)!\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,
10463
- lookbehind: true,
10464
- greedy: true,
10465
- inside: comment_inside
10466
- }
10467
- ],
10468
- number: [
10469
- {
10470
- // basic base 10 integers 9, -9
10471
- pattern: /(^|\s)[+-]?\d+(?=\s|$)/,
10472
- lookbehind: true
10473
- },
10474
- {
10475
- // base prefix integers 0b010 0o70 0xad 0d10 0XAD -0xa9
10476
- pattern: /(^|\s)[+-]?0(?:b[01]+|o[0-7]+|d\d+|x[\dA-F]+)(?=\s|$)/i,
10477
- lookbehind: true
10478
- },
10479
- {
10480
- // fractional ratios 1/5 -1/5 and the literal float approximations 1/5. -1/5.
10481
- pattern: /(^|\s)[+-]?\d+\/\d+\.?(?=\s|$)/,
10482
- lookbehind: true
10483
- },
10484
- {
10485
- // positive mixed numbers 23+1/5 +23+1/5
10486
- pattern: /(^|\s)\+?\d+\+\d+\/\d+(?=\s|$)/,
10487
- lookbehind: true
10488
- },
10489
- {
10490
- // negative mixed numbers -23-1/5
10491
- pattern: /(^|\s)-\d+-\d+\/\d+(?=\s|$)/,
10492
- lookbehind: true
10493
- },
10494
- {
10495
- // basic decimal floats -0.01 0. .0 .1 -.1 -1. -12.13 +12.13
10496
- // and scientific notation with base 10 exponents 3e4 3e-4 .3e-4
10497
- pattern:
10498
- /(^|\s)[+-]?(?:\d*\.\d+|\d+\.\d*|\d+)(?:e[+-]?\d+)?(?=\s|$)/i,
10499
- lookbehind: true
10500
- },
10501
- {
10502
- // NAN literal syntax NAN: 80000deadbeef, NAN: a
10503
- pattern: /(^|\s)NAN:\s+[\da-fA-F]+(?=\s|$)/,
10504
- lookbehind: true
10505
- },
10506
- {
10507
- /*
10508
- base prefix floats 0x1.0p3 (8.0) 0b1.010p2 (5.0) 0x1.p1 0b1.11111111p11111...
10509
- "The normalized hex form ±0x1.MMMMMMMMMMMMM[pP]±EEEE allows any floating-point number to be specified precisely.
10510
- The values of MMMMMMMMMMMMM and EEEE map directly to the mantissa and exponent fields of the binary IEEE 754 representation."
10511
- <https://docs.factorcode.org/content/article-syntax-floats.html>
10512
- */
10513
- pattern:
10514
- /(^|\s)[+-]?0(?:b1\.[01]*|o1\.[0-7]*|d1\.\d*|x1\.[\dA-F]*)p\d+(?=\s|$)/i,
10515
- lookbehind: true
10516
- }
10517
- ],
10518
- // R/ regexp?\/\\/
10519
- regexp: {
10520
- pattern:
10521
- /(^|\s)R\/\s(?:\\\S|[^\\/])*\/(?:[idmsr]*|[idmsr]+-[idmsr]+)(?=\s|$)/,
10522
- lookbehind: true,
10523
- alias: 'number',
10524
- inside: {
10525
- variable: /\\\S/,
10526
- keyword: /[+?*\[\]^$(){}.|]/,
10527
- operator: {
10528
- pattern: /(\/)[idmsr]+(?:-[idmsr]+)?/,
10529
- lookbehind: true
10530
- }
10531
- }
10532
- },
10533
- boolean: {
10534
- pattern: /(^|\s)[tf](?=\s|$)/,
10535
- lookbehind: true
10536
- },
10537
- // SBUF" asd", URL" ://...", P" /etc/"
10538
- 'custom-string': {
10539
- pattern: /(^|\s)[A-Z0-9\-]+"\s(?:\\\S|[^"\\])*"/,
10540
- lookbehind: true,
10541
- greedy: true,
10542
- alias: 'string',
10543
- inside: {
10544
- number: /\\\S|%\w|\//
10545
- }
10546
- },
10547
- 'multiline-string': [
10548
- {
10549
- // STRING: name \n content \n ; -> CONSTANT: name "content" (symbol)
10550
- pattern: /(^|\s)STRING:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*;(?=\s|$)/,
10551
- lookbehind: true,
10552
- greedy: true,
10553
- alias: 'string',
10554
- inside: {
10555
- number: string_inside.number,
10556
- // trailing semicolon on its own line
10557
- 'semicolon-or-setlocal': {
10558
- pattern: /([\r\n][ \t]*);(?=\s|$)/,
10559
- lookbehind: true,
10560
- alias: 'function'
10561
- }
10562
- }
10563
- },
10564
- {
10565
- // HEREDOC: marker \n content \n marker ; -> "content" (immediate)
10566
- pattern: /(^|\s)HEREDOC:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*\S+(?=\s|$)/,
10567
- lookbehind: true,
10568
- greedy: true,
10569
- alias: 'string',
10570
- inside: string_inside
10571
- },
10572
- {
10573
- // [[ string ]], [==[ string]==]
10574
- pattern: /(^|\s)\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,
10575
- lookbehind: true,
10576
- greedy: true,
10577
- alias: 'string',
10578
- inside: string_inside
10579
- }
10580
- ],
10581
- 'special-using': {
10582
- pattern: /(^|\s)USING:(?:\s\S+)*(?=\s+;(?:\s|$))/,
10583
- lookbehind: true,
10584
- alias: 'function',
10585
- inside: {
10586
- // this is essentially a regex for vocab names, which i don't want to specify
10587
- // but the USING: gets picked up as a vocab name
10588
- string: {
10589
- pattern: /(\s)[^:\s]+/,
10590
- lookbehind: true
10591
- }
10592
- }
10593
- },
10594
- /* this description of stack effect literal syntax is not complete and not as specific as theoretically possible
10595
- trying to do better is more work and regex-computation-time than it's worth though.
10596
- - we'd like to have the "delimiter" parts of the stack effect [ (, --, and ) ] be a different (less-important or comment-like) colour to the stack effect contents
10597
- - we'd like if nested stack effects were treated as such rather than just appearing flat (with `inside`)
10598
- - we'd like if the following variable name conventions were recognised specifically:
10599
- special row variables = ..a b..
10600
- type and stack effect annotations end with a colon = ( quot: ( a: ( -- ) -- b ) -- x ), ( x: number -- )
10601
- word throws unconditional error = *
10602
- any other word-like variable name = a ? q' etc
10603
- https://docs.factorcode.org/content/article-effects.html
10604
- these are pretty complicated to highlight properly without a real parser, and therefore out of scope
10605
- the old pattern, which may be later useful, was: (^|\s)(?:call|execute|eval)?\((?:\s+[^"\r\n\t ]\S*)*?\s+--(?:\s+[^"\n\t ]\S*)*?\s+\)(?=\s|$)
10606
- */
10607
- // current solution is not great
10608
- 'stack-effect-delimiter': [
10609
- {
10610
- // opening parenthesis
10611
- pattern: /(^|\s)(?:call|eval|execute)?\((?=\s)/,
10612
- lookbehind: true,
10613
- alias: 'operator'
10614
- },
10615
- {
10616
- // middle --
10617
- pattern: /(\s)--(?=\s)/,
10618
- lookbehind: true,
10619
- alias: 'operator'
10620
- },
10621
- {
10622
- // closing parenthesis
10623
- pattern: /(\s)\)(?=\s|$)/,
10624
- lookbehind: true,
10625
- alias: 'operator'
10626
- }
10627
- ],
10628
- combinators: {
10629
- pattern: null,
10630
- lookbehind: true,
10631
- alias: 'keyword'
10632
- },
10633
- 'kernel-builtin': {
10634
- pattern: null,
10635
- lookbehind: true,
10636
- alias: 'variable'
10637
- },
10638
- 'sequences-builtin': {
10639
- pattern: null,
10640
- lookbehind: true,
10641
- alias: 'variable'
10642
- },
10643
- 'math-builtin': {
10644
- pattern: null,
10645
- lookbehind: true,
10646
- alias: 'variable'
10647
- },
10648
- 'constructor-word': {
10649
- // <array> but not <=>
10650
- pattern: /(^|\s)<(?!=+>|-+>)\S+>(?=\s|$)/,
10651
- lookbehind: true,
10652
- alias: 'keyword'
10653
- },
10654
- 'other-builtin-syntax': {
10655
- pattern: null,
10656
- lookbehind: true,
10657
- alias: 'operator'
10658
- },
10659
- /*
10660
- full list of supported word naming conventions: (the convention appears outside of the [brackets])
10661
- set-[x]
10662
- change-[x]
10663
- with-[x]
10664
- new-[x]
10665
- >[string]
10666
- [base]>
10667
- [string]>[number]
10668
- +[symbol]+
10669
- [boolean-word]?
10670
- ?[of]
10671
- [slot-reader]>>
10672
- >>[slot-setter]
10673
- [slot-writer]<<
10674
- ([implementation-detail])
10675
- [mutater]!
10676
- [variant]*
10677
- [prettyprint].
10678
- $[help-markup]
10679
- <constructors>, SYNTAX:, etc are supported by their own patterns.
10680
- `with` and `new` from `kernel` are their own builtins.
10681
- see <https://docs.factorcode.org/content/article-conventions.html>
10682
- */
10683
- 'conventionally-named-word': {
10684
- pattern:
10685
- /(^|\s)(?!")(?:(?:change|new|set|with)-\S+|\$\S+|>[^>\s]+|[^:>\s]+>|[^>\s]+>[^>\s]+|\+[^+\s]+\+|[^?\s]+\?|\?[^?\s]+|[^>\s]+>>|>>[^>\s]+|[^<\s]+<<|\([^()\s]+\)|[^!\s]+!|[^*\s]\S*\*|[^.\s]\S*\.)(?=\s|$)/,
10686
- lookbehind: true,
10687
- alias: 'keyword'
10688
- },
10689
- 'colon-syntax': {
10690
- pattern: /(^|\s)(?:[A-Z0-9\-]+#?)?:{1,2}\s+(?:;\S+|(?!;)\S+)(?=\s|$)/,
10691
- lookbehind: true,
10692
- greedy: true,
10693
- alias: 'function'
10694
- },
10695
- 'semicolon-or-setlocal': {
10696
- pattern: /(\s)(?:;|:>)(?=\s|$)/,
10697
- lookbehind: true,
10698
- alias: 'function'
10699
- },
10700
- // do not highlight leading } or trailing X{ at the begin/end of the file as it's invalid syntax
10701
- 'curly-brace-literal-delimiter': [
10702
- {
10703
- // opening
10704
- pattern: /(^|\s)[a-z]*\{(?=\s)/i,
10705
- lookbehind: true,
10706
- alias: 'operator'
10707
- },
10708
- {
10709
- // closing
10710
- pattern: /(\s)\}(?=\s|$)/,
10711
- lookbehind: true,
10712
- alias: 'operator'
10713
- }
10714
- ],
10715
- // do not highlight leading ] or trailing [ at the begin/end of the file as it's invalid syntax
10716
- 'quotation-delimiter': [
10717
- {
10718
- // opening
10719
- pattern: /(^|\s)\[(?=\s)/,
10720
- lookbehind: true,
10721
- alias: 'operator'
10722
- },
10723
- {
10724
- // closing
10725
- pattern: /(\s)\](?=\s|$)/,
10726
- lookbehind: true,
10727
- alias: 'operator'
10728
- }
10729
- ],
10730
- 'normal-word': {
10731
- pattern: /(^|\s)[^"\s]\S*(?=\s|$)/,
10732
- lookbehind: true
10733
- },
10734
- /*
10735
- basic first-class string "a"
10736
- with escaped double-quote "a\""
10737
- escaped backslash "\\"
10738
- and general escapes since Factor has so many "\N"
10739
- syntax that works in the reference implementation that isn't fully
10740
- supported because it's an implementation detail:
10741
- "string 1""string 2" -> 2 strings (works anyway)
10742
- "string"5 -> string, 5
10743
- "string"[ ] -> string, quotation
10744
- { "a"} -> array<string>
10745
- the rest of those examples all properly recognise the string, but not
10746
- the other object (number, quotation, etc)
10747
- this is fine for a regex-only implementation.
10748
- */
10749
- string: {
10750
- pattern: /"(?:\\\S|[^"\\])*"/,
10751
- greedy: true,
10752
- inside: string_inside
10753
- }
10754
- };
10755
- var escape = function (str) {
10756
- return (str + '').replace(/([.?*+\^$\[\]\\(){}|\-])/g, '\\$1')
10757
- };
10758
- var arrToWordsRegExp = function (arr) {
10759
- return new RegExp('(^|\\s)(?:' + arr.map(escape).join('|') + ')(?=\\s|$)')
10760
- };
10761
- var builtins = {
10762
- 'kernel-builtin': [
10763
- 'or',
10764
- '2nipd',
10765
- '4drop',
10766
- 'tuck',
10767
- 'wrapper',
10768
- 'nip',
10769
- 'wrapper?',
10770
- 'callstack>array',
10771
- 'die',
10772
- 'dupd',
10773
- 'callstack',
10774
- 'callstack?',
10775
- '3dup',
10776
- 'hashcode',
10777
- 'pick',
10778
- '4nip',
10779
- 'build',
10780
- '>boolean',
10781
- 'nipd',
10782
- 'clone',
10783
- '5nip',
10784
- 'eq?',
10785
- '?',
10786
- '=',
10787
- 'swapd',
10788
- '2over',
10789
- 'clear',
10790
- '2dup',
10791
- 'get-retainstack',
10792
- 'not',
10793
- 'tuple?',
10794
- 'dup',
10795
- '3nipd',
10796
- 'call',
10797
- '-rotd',
10798
- 'object',
10799
- 'drop',
10800
- 'assert=',
10801
- 'assert?',
10802
- '-rot',
10803
- 'execute',
10804
- 'boa',
10805
- 'get-callstack',
10806
- 'curried?',
10807
- '3drop',
10808
- 'pickd',
10809
- 'overd',
10810
- 'over',
10811
- 'roll',
10812
- '3nip',
10813
- 'swap',
10814
- 'and',
10815
- '2nip',
10816
- 'rotd',
10817
- 'throw',
10818
- '(clone)',
10819
- 'hashcode*',
10820
- 'spin',
10821
- 'reach',
10822
- '4dup',
10823
- 'equal?',
10824
- 'get-datastack',
10825
- 'assert',
10826
- '2drop',
10827
- '<wrapper>',
10828
- 'boolean?',
10829
- 'identity-hashcode',
10830
- 'identity-tuple?',
10831
- 'null',
10832
- 'composed?',
10833
- 'new',
10834
- '5drop',
10835
- 'rot',
10836
- '-roll',
10837
- 'xor',
10838
- 'identity-tuple',
10839
- 'boolean'
10840
- ],
10841
- 'other-builtin-syntax': [
10842
- // syntax
10843
- '=======',
10844
- 'recursive',
10845
- 'flushable',
10846
- '>>',
10847
- '<<<<<<',
10848
- 'M\\',
10849
- 'B',
10850
- 'PRIVATE>',
10851
- '\\',
10852
- '======',
10853
- 'final',
10854
- 'inline',
10855
- 'delimiter',
10856
- 'deprecated',
10857
- '<PRIVATE',
10858
- '>>>>>>',
10859
- '<<<<<<<',
10860
- 'parse-complex',
10861
- 'malformed-complex',
10862
- 'read-only',
10863
- '>>>>>>>',
10864
- 'call-next-method',
10865
- '<<',
10866
- 'foldable', // literals
10867
- '$',
10868
- '$[',
10869
- '${'
10870
- ],
10871
- 'sequences-builtin': [
10872
- 'member-eq?',
10873
- 'mismatch',
10874
- 'append',
10875
- 'assert-sequence=',
10876
- 'longer',
10877
- 'repetition',
10878
- 'clone-like',
10879
- '3sequence',
10880
- 'assert-sequence?',
10881
- 'last-index-from',
10882
- 'reversed',
10883
- 'index-from',
10884
- 'cut*',
10885
- 'pad-tail',
10886
- 'join-as',
10887
- 'remove-eq!',
10888
- 'concat-as',
10889
- 'but-last',
10890
- 'snip',
10891
- 'nths',
10892
- 'nth',
10893
- 'sequence',
10894
- 'longest',
10895
- 'slice?',
10896
- '<slice>',
10897
- 'remove-nth',
10898
- 'tail-slice',
10899
- 'empty?',
10900
- 'tail*',
10901
- 'member?',
10902
- 'virtual-sequence?',
10903
- 'set-length',
10904
- 'drop-prefix',
10905
- 'iota',
10906
- 'unclip',
10907
- 'bounds-error?',
10908
- 'unclip-last-slice',
10909
- 'non-negative-integer-expected',
10910
- 'non-negative-integer-expected?',
10911
- 'midpoint@',
10912
- 'longer?',
10913
- '?set-nth',
10914
- '?first',
10915
- 'rest-slice',
10916
- 'prepend-as',
10917
- 'prepend',
10918
- 'fourth',
10919
- 'sift',
10920
- 'subseq-start',
10921
- 'new-sequence',
10922
- '?last',
10923
- 'like',
10924
- 'first4',
10925
- '1sequence',
10926
- 'reverse',
10927
- 'slice',
10928
- 'virtual@',
10929
- 'repetition?',
10930
- 'set-last',
10931
- 'index',
10932
- '4sequence',
10933
- 'max-length',
10934
- 'set-second',
10935
- 'immutable-sequence',
10936
- 'first2',
10937
- 'first3',
10938
- 'supremum',
10939
- 'unclip-slice',
10940
- 'suffix!',
10941
- 'insert-nth',
10942
- 'tail',
10943
- '3append',
10944
- 'short',
10945
- 'suffix',
10946
- 'concat',
10947
- 'flip',
10948
- 'immutable?',
10949
- 'reverse!',
10950
- '2sequence',
10951
- 'sum',
10952
- 'delete-all',
10953
- 'indices',
10954
- 'snip-slice',
10955
- '<iota>',
10956
- 'check-slice',
10957
- 'sequence?',
10958
- 'head',
10959
- 'append-as',
10960
- 'halves',
10961
- 'sequence=',
10962
- 'collapse-slice',
10963
- '?second',
10964
- 'slice-error?',
10965
- 'product',
10966
- 'bounds-check?',
10967
- 'bounds-check',
10968
- 'immutable',
10969
- 'virtual-exemplar',
10970
- 'harvest',
10971
- 'remove',
10972
- 'pad-head',
10973
- 'last',
10974
- 'set-fourth',
10975
- 'cartesian-product',
10976
- 'remove-eq',
10977
- 'shorten',
10978
- 'shorter',
10979
- 'reversed?',
10980
- 'shorter?',
10981
- 'shortest',
10982
- 'head-slice',
10983
- 'pop*',
10984
- 'tail-slice*',
10985
- 'but-last-slice',
10986
- 'iota?',
10987
- 'append!',
10988
- 'cut-slice',
10989
- 'new-resizable',
10990
- 'head-slice*',
10991
- 'sequence-hashcode',
10992
- 'pop',
10993
- 'set-nth',
10994
- '?nth',
10995
- 'second',
10996
- 'join',
10997
- 'immutable-sequence?',
10998
- '<reversed>',
10999
- '3append-as',
11000
- 'virtual-sequence',
11001
- 'subseq?',
11002
- 'remove-nth!',
11003
- 'length',
11004
- 'last-index',
11005
- 'lengthen',
11006
- 'assert-sequence',
11007
- 'copy',
11008
- 'move',
11009
- 'third',
11010
- 'first',
11011
- 'tail?',
11012
- 'set-first',
11013
- 'prefix',
11014
- 'bounds-error',
11015
- '<repetition>',
11016
- 'exchange',
11017
- 'surround',
11018
- 'cut',
11019
- 'min-length',
11020
- 'set-third',
11021
- 'push-all',
11022
- 'head?',
11023
- 'subseq-start-from',
11024
- 'delete-slice',
11025
- 'rest',
11026
- 'sum-lengths',
11027
- 'head*',
11028
- 'infimum',
11029
- 'remove!',
11030
- 'glue',
11031
- 'slice-error',
11032
- 'subseq',
11033
- 'push',
11034
- 'replace-slice',
11035
- 'subseq-as',
11036
- 'unclip-last'
11037
- ],
11038
- 'math-builtin': [
11039
- 'number=',
11040
- 'next-power-of-2',
11041
- '?1+',
11042
- 'fp-special?',
11043
- 'imaginary-part',
11044
- 'float>bits',
11045
- 'number?',
11046
- 'fp-infinity?',
11047
- 'bignum?',
11048
- 'fp-snan?',
11049
- 'denominator',
11050
- 'gcd',
11051
- '*',
11052
- '+',
11053
- 'fp-bitwise=',
11054
- '-',
11055
- 'u>=',
11056
- '/',
11057
- '>=',
11058
- 'bitand',
11059
- 'power-of-2?',
11060
- 'log2-expects-positive',
11061
- 'neg?',
11062
- '<',
11063
- 'log2',
11064
- '>',
11065
- 'integer?',
11066
- 'number',
11067
- 'bits>double',
11068
- '2/',
11069
- 'zero?',
11070
- 'bits>float',
11071
- 'float?',
11072
- 'shift',
11073
- 'ratio?',
11074
- 'rect>',
11075
- 'even?',
11076
- 'ratio',
11077
- 'fp-sign',
11078
- 'bitnot',
11079
- '>fixnum',
11080
- 'complex?',
11081
- '/i',
11082
- 'integer>fixnum',
11083
- '/f',
11084
- 'sgn',
11085
- '>bignum',
11086
- 'next-float',
11087
- 'u<',
11088
- 'u>',
11089
- 'mod',
11090
- 'recip',
11091
- 'rational',
11092
- '>float',
11093
- '2^',
11094
- 'integer',
11095
- 'fixnum?',
11096
- 'neg',
11097
- 'fixnum',
11098
- 'sq',
11099
- 'bignum',
11100
- '>rect',
11101
- 'bit?',
11102
- 'fp-qnan?',
11103
- 'simple-gcd',
11104
- 'complex',
11105
- '<fp-nan>',
11106
- 'real',
11107
- '>fraction',
11108
- 'double>bits',
11109
- 'bitor',
11110
- 'rem',
11111
- 'fp-nan-payload',
11112
- 'real-part',
11113
- 'log2-expects-positive?',
11114
- 'prev-float',
11115
- 'align',
11116
- 'unordered?',
11117
- 'float',
11118
- 'fp-nan?',
11119
- 'abs',
11120
- 'bitxor',
11121
- 'integer>fixnum-strict',
11122
- 'u<=',
11123
- 'odd?',
11124
- '<=',
11125
- '/mod',
11126
- '>integer',
11127
- 'real?',
11128
- 'rational?',
11129
- 'numerator'
11130
- ] // that's all for now
11131
- };
11132
- Object.keys(builtins).forEach(function (k) {
11133
- factor[k].pattern = arrToWordsRegExp(builtins[k]);
11134
- });
11135
- var combinators = [
11136
- // kernel
11137
- '2bi',
11138
- 'while',
11139
- '2tri',
11140
- 'bi*',
11141
- '4dip',
11142
- 'both?',
11143
- 'same?',
11144
- 'tri@',
11145
- 'curry',
11146
- 'prepose',
11147
- '3bi',
11148
- '?if',
11149
- 'tri*',
11150
- '2keep',
11151
- '3keep',
11152
- 'curried',
11153
- '2keepd',
11154
- 'when',
11155
- '2bi*',
11156
- '2tri*',
11157
- '4keep',
11158
- 'bi@',
11159
- 'keepdd',
11160
- 'do',
11161
- 'unless*',
11162
- 'tri-curry',
11163
- 'if*',
11164
- 'loop',
11165
- 'bi-curry*',
11166
- 'when*',
11167
- '2bi@',
11168
- '2tri@',
11169
- 'with',
11170
- '2with',
11171
- 'either?',
11172
- 'bi',
11173
- 'until',
11174
- '3dip',
11175
- '3curry',
11176
- 'tri-curry*',
11177
- 'tri-curry@',
11178
- 'bi-curry',
11179
- 'keepd',
11180
- 'compose',
11181
- '2dip',
11182
- 'if',
11183
- '3tri',
11184
- 'unless',
11185
- 'tuple',
11186
- 'keep',
11187
- '2curry',
11188
- 'tri',
11189
- 'most',
11190
- 'while*',
11191
- 'dip',
11192
- 'composed',
11193
- 'bi-curry@', // sequences
11194
- 'find-last-from',
11195
- 'trim-head-slice',
11196
- 'map-as',
11197
- 'each-from',
11198
- 'none?',
11199
- 'trim-tail',
11200
- 'partition',
11201
- 'if-empty',
11202
- 'accumulate*',
11203
- 'reject!',
11204
- 'find-from',
11205
- 'accumulate-as',
11206
- 'collector-for-as',
11207
- 'reject',
11208
- 'map',
11209
- 'map-sum',
11210
- 'accumulate!',
11211
- '2each-from',
11212
- 'follow',
11213
- 'supremum-by',
11214
- 'map!',
11215
- 'unless-empty',
11216
- 'collector',
11217
- 'padding',
11218
- 'reduce-index',
11219
- 'replicate-as',
11220
- 'infimum-by',
11221
- 'trim-tail-slice',
11222
- 'count',
11223
- 'find-index',
11224
- 'filter',
11225
- 'accumulate*!',
11226
- 'reject-as',
11227
- 'map-integers',
11228
- 'map-find',
11229
- 'reduce',
11230
- 'selector',
11231
- 'interleave',
11232
- '2map',
11233
- 'filter-as',
11234
- 'binary-reduce',
11235
- 'map-index-as',
11236
- 'find',
11237
- 'produce',
11238
- 'filter!',
11239
- 'replicate',
11240
- 'cartesian-map',
11241
- 'cartesian-each',
11242
- 'find-index-from',
11243
- 'map-find-last',
11244
- '3map-as',
11245
- '3map',
11246
- 'find-last',
11247
- 'selector-as',
11248
- '2map-as',
11249
- '2map-reduce',
11250
- 'accumulate',
11251
- 'each',
11252
- 'each-index',
11253
- 'accumulate*-as',
11254
- 'when-empty',
11255
- 'all?',
11256
- 'collector-as',
11257
- 'push-either',
11258
- 'new-like',
11259
- 'collector-for',
11260
- '2selector',
11261
- 'push-if',
11262
- '2all?',
11263
- 'map-reduce',
11264
- '3each',
11265
- 'any?',
11266
- 'trim-slice',
11267
- '2reduce',
11268
- 'change-nth',
11269
- 'produce-as',
11270
- '2each',
11271
- 'trim',
11272
- 'trim-head',
11273
- 'cartesian-find',
11274
- 'map-index', // math
11275
- 'if-zero',
11276
- 'each-integer',
11277
- 'unless-zero',
11278
- '(find-integer)',
11279
- 'when-zero',
11280
- 'find-last-integer',
11281
- '(all-integers?)',
11282
- 'times',
11283
- '(each-integer)',
11284
- 'find-integer',
11285
- 'all-integers?', // math.combinators
11286
- 'unless-negative',
11287
- 'if-positive',
11288
- 'when-positive',
11289
- 'when-negative',
11290
- 'unless-positive',
11291
- 'if-negative', // combinators
11292
- 'case',
11293
- '2cleave',
11294
- 'cond>quot',
11295
- 'case>quot',
11296
- '3cleave',
11297
- 'wrong-values',
11298
- 'to-fixed-point',
11299
- 'alist>quot',
11300
- 'cond',
11301
- 'cleave',
11302
- 'call-effect',
11303
- 'recursive-hashcode',
11304
- 'spread',
11305
- 'deep-spread>quot', // combinators.short-circuit
11306
- '2||',
11307
- '0||',
11308
- 'n||',
11309
- '0&&',
11310
- '2&&',
11311
- '3||',
11312
- '1||',
11313
- '1&&',
11314
- 'n&&',
11315
- '3&&', // combinators.smart
11316
- 'smart-unless*',
11317
- 'keep-inputs',
11318
- 'reduce-outputs',
11319
- 'smart-when*',
11320
- 'cleave>array',
11321
- 'smart-with',
11322
- 'smart-apply',
11323
- 'smart-if',
11324
- 'inputs/outputs',
11325
- 'output>sequence-n',
11326
- 'map-outputs',
11327
- 'map-reduce-outputs',
11328
- 'dropping',
11329
- 'output>array',
11330
- 'smart-map-reduce',
11331
- 'smart-2map-reduce',
11332
- 'output>array-n',
11333
- 'nullary',
11334
- 'input<sequence',
11335
- 'append-outputs',
11336
- 'drop-inputs',
11337
- 'inputs',
11338
- 'smart-2reduce',
11339
- 'drop-outputs',
11340
- 'smart-reduce',
11341
- 'preserving',
11342
- 'smart-when',
11343
- 'outputs',
11344
- 'append-outputs-as',
11345
- 'smart-unless',
11346
- 'smart-if*',
11347
- 'sum-outputs',
11348
- 'input<sequence-unsafe',
11349
- 'output>sequence' // tafn
11350
- ];
11351
- factor.combinators.pattern = arrToWordsRegExp(combinators);
11352
- Prism.languages.factor = factor;
11353
- })(Prism);
10300
+ var erlang_1;
10301
+ var hasRequiredErlang;
10302
+
10303
+ function requireErlang () {
10304
+ if (hasRequiredErlang) return erlang_1;
10305
+ hasRequiredErlang = 1;
10306
+
10307
+ erlang_1 = erlang;
10308
+ erlang.displayName = 'erlang';
10309
+ erlang.aliases = [];
10310
+ function erlang(Prism) {
10311
+ Prism.languages.erlang = {
10312
+ comment: /%.+/,
10313
+ string: {
10314
+ pattern: /"(?:\\.|[^\\"\r\n])*"/,
10315
+ greedy: true
10316
+ },
10317
+ 'quoted-function': {
10318
+ pattern: /'(?:\\.|[^\\'\r\n])+'(?=\()/,
10319
+ alias: 'function'
10320
+ },
10321
+ 'quoted-atom': {
10322
+ pattern: /'(?:\\.|[^\\'\r\n])+'/,
10323
+ alias: 'atom'
10324
+ },
10325
+ boolean: /\b(?:false|true)\b/,
10326
+ keyword: /\b(?:after|case|catch|end|fun|if|of|receive|try|when)\b/,
10327
+ number: [
10328
+ /\$\\?./,
10329
+ /\b\d+#[a-z0-9]+/i,
10330
+ /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i
10331
+ ],
10332
+ function: /\b[a-z][\w@]*(?=\()/,
10333
+ variable: {
10334
+ // Look-behind is used to prevent wrong highlighting of atoms containing "@"
10335
+ pattern: /(^|[^@])(?:\b|\?)[A-Z_][\w@]*/,
10336
+ lookbehind: true
10337
+ },
10338
+ operator: [
10339
+ /[=\/<>:]=|=[:\/]=|\+\+?|--?|[=*\/!]|\b(?:and|andalso|band|bnot|bor|bsl|bsr|bxor|div|not|or|orelse|rem|xor)\b/,
10340
+ {
10341
+ // We don't want to match <<
10342
+ pattern: /(^|[^<])<(?!<)/,
10343
+ lookbehind: true
10344
+ },
10345
+ {
10346
+ // We don't want to match >>
10347
+ pattern: /(^|[^>])>(?!>)/,
10348
+ lookbehind: true
10349
+ }
10350
+ ],
10351
+ atom: /\b[a-z][\w@]*/,
10352
+ punctuation: /[()[\]{}:;,.#|]|<<|>>/
10353
+ };
10354
+ }
10355
+ return erlang_1;
10356
+ }
10357
+
10358
+ var lua_1;
10359
+ var hasRequiredLua;
10360
+
10361
+ function requireLua () {
10362
+ if (hasRequiredLua) return lua_1;
10363
+ hasRequiredLua = 1;
10364
+
10365
+ lua_1 = lua;
10366
+ lua.displayName = 'lua';
10367
+ lua.aliases = [];
10368
+ function lua(Prism) {
10369
+ Prism.languages.lua = {
10370
+ comment: /^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,
10371
+ // \z may be used to skip the following space
10372
+ string: {
10373
+ pattern:
10374
+ /(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,
10375
+ greedy: true
10376
+ },
10377
+ number:
10378
+ /\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,
10379
+ keyword:
10380
+ /\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,
10381
+ function: /(?!\d)\w+(?=\s*(?:[({]))/,
10382
+ operator: [
10383
+ /[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,
10384
+ {
10385
+ // Match ".." but don't break "..."
10386
+ pattern: /(^|[^.])\.\.(?!\.)/,
10387
+ lookbehind: true
10388
+ }
10389
+ ],
10390
+ punctuation: /[\[\](){},;]|\.+|:+/
10391
+ };
10392
+ }
10393
+ return lua_1;
10394
+ }
10395
+
10396
+ var etlua_1;
10397
+ var hasRequiredEtlua;
10398
+
10399
+ function requireEtlua () {
10400
+ if (hasRequiredEtlua) return etlua_1;
10401
+ hasRequiredEtlua = 1;
10402
+ var refractorLua = requireLua();
10403
+ var refractorMarkupTemplating = requireMarkupTemplating();
10404
+ etlua_1 = etlua;
10405
+ etlua.displayName = 'etlua';
10406
+ etlua.aliases = [];
10407
+ function etlua(Prism) {
10408
+ Prism.register(refractorLua);
10409
+ Prism.register(refractorMarkupTemplating)
10410
+ ;(function (Prism) {
10411
+ Prism.languages.etlua = {
10412
+ delimiter: {
10413
+ pattern: /^<%[-=]?|-?%>$/,
10414
+ alias: 'punctuation'
10415
+ },
10416
+ 'language-lua': {
10417
+ pattern: /[\s\S]+/,
10418
+ inside: Prism.languages.lua
10419
+ }
10420
+ };
10421
+ Prism.hooks.add('before-tokenize', function (env) {
10422
+ var pattern = /<%[\s\S]+?%>/g;
10423
+ Prism.languages['markup-templating'].buildPlaceholders(
10424
+ env,
10425
+ 'etlua',
10426
+ pattern
10427
+ );
10428
+ });
10429
+ Prism.hooks.add('after-tokenize', function (env) {
10430
+ Prism.languages['markup-templating'].tokenizePlaceholders(env, 'etlua');
10431
+ });
10432
+ })(Prism);
10433
+ }
10434
+ return etlua_1;
10435
+ }
10436
+
10437
+ var excelFormula_1;
10438
+ var hasRequiredExcelFormula;
10439
+
10440
+ function requireExcelFormula () {
10441
+ if (hasRequiredExcelFormula) return excelFormula_1;
10442
+ hasRequiredExcelFormula = 1;
10443
+
10444
+ excelFormula_1 = excelFormula;
10445
+ excelFormula.displayName = 'excelFormula';
10446
+ excelFormula.aliases = [];
10447
+ function excelFormula(Prism) {
10448
+ Prism.languages['excel-formula'] = {
10449
+ comment: {
10450
+ pattern: /(\bN\(\s*)"(?:[^"]|"")*"(?=\s*\))/i,
10451
+ lookbehind: true,
10452
+ greedy: true
10453
+ },
10454
+ string: {
10455
+ pattern: /"(?:[^"]|"")*"(?!")/,
10456
+ greedy: true
10457
+ },
10458
+ reference: {
10459
+ // https://www.ablebits.com/office-addins-blog/2015/12/08/excel-reference-another-sheet-workbook/
10460
+ // Sales!B2
10461
+ // 'Winter sales'!B2
10462
+ // [Sales.xlsx]Jan!B2:B5
10463
+ // D:\Reports\[Sales.xlsx]Jan!B2:B5
10464
+ // '[Sales.xlsx]Jan sales'!B2:B5
10465
+ // 'D:\Reports\[Sales.xlsx]Jan sales'!B2:B5
10466
+ pattern:
10467
+ /(?:'[^']*'|(?:[^\s()[\]{}<>*?"';,$&]*\[[^^\s()[\]{}<>*?"']+\])?\w+)!/,
10468
+ greedy: true,
10469
+ alias: 'string',
10470
+ inside: {
10471
+ operator: /!$/,
10472
+ punctuation: /'/,
10473
+ sheet: {
10474
+ pattern: /[^[\]]+$/,
10475
+ alias: 'function'
10476
+ },
10477
+ file: {
10478
+ pattern: /\[[^[\]]+\]$/,
10479
+ inside: {
10480
+ punctuation: /[[\]]/
10481
+ }
10482
+ },
10483
+ path: /[\s\S]+/
10484
+ }
10485
+ },
10486
+ 'function-name': {
10487
+ pattern: /\b[A-Z]\w*(?=\()/i,
10488
+ alias: 'keyword'
10489
+ },
10490
+ range: {
10491
+ pattern:
10492
+ /\$?\b(?:[A-Z]+\$?\d+:\$?[A-Z]+\$?\d+|[A-Z]+:\$?[A-Z]+|\d+:\$?\d+)\b/i,
10493
+ alias: 'property',
10494
+ inside: {
10495
+ operator: /:/,
10496
+ cell: /\$?[A-Z]+\$?\d+/i,
10497
+ column: /\$?[A-Z]+/i,
10498
+ row: /\$?\d+/
10499
+ }
10500
+ },
10501
+ cell: {
10502
+ // Excel is case insensitive, so the string "foo1" could be either a variable or a cell.
10503
+ // To combat this, we match cells case insensitive, if the contain at least one "$", and case sensitive otherwise.
10504
+ pattern: /\b[A-Z]+\d+\b|\$[A-Za-z]+\$?\d+\b|\b[A-Za-z]+\$\d+\b/,
10505
+ alias: 'property'
10506
+ },
10507
+ number: /(?:\b\d+(?:\.\d+)?|\B\.\d+)(?:e[+-]?\d+)?\b/i,
10508
+ boolean: /\b(?:FALSE|TRUE)\b/i,
10509
+ operator: /[-+*/^%=&,]|<[=>]?|>=?/,
10510
+ punctuation: /[[\]();{}|]/
10511
+ };
10512
+ Prism.languages['xlsx'] = Prism.languages['xls'] =
10513
+ Prism.languages['excel-formula'];
10514
+ }
10515
+ return excelFormula_1;
10516
+ }
10517
+
10518
+ var factor_1;
10519
+ var hasRequiredFactor;
10520
+
10521
+ function requireFactor () {
10522
+ if (hasRequiredFactor) return factor_1;
10523
+ hasRequiredFactor = 1;
10524
+
10525
+ factor_1 = factor;
10526
+ factor.displayName = 'factor';
10527
+ factor.aliases = [];
10528
+ function factor(Prism) {
10529
+ (function (Prism) {
10530
+ var comment_inside = {
10531
+ function:
10532
+ /\b(?:BUGS?|FIX(?:MES?)?|NOTES?|TODOS?|XX+|HACKS?|WARN(?:ING)?|\?{2,}|!{2,})\b/
10533
+ };
10534
+ var string_inside = {
10535
+ number: /\\[^\s']|%\w/
10536
+ };
10537
+ var factor = {
10538
+ comment: [
10539
+ {
10540
+ // ! single-line exclamation point comments with whitespace after/around the !
10541
+ pattern: /(^|\s)(?:! .*|!$)/,
10542
+ lookbehind: true,
10543
+ inside: comment_inside
10544
+ },
10545
+ /* from basis/multiline: */
10546
+ {
10547
+ // /* comment */, /* comment*/
10548
+ pattern: /(^|\s)\/\*\s[\s\S]*?\*\/(?=\s|$)/,
10549
+ lookbehind: true,
10550
+ greedy: true,
10551
+ inside: comment_inside
10552
+ },
10553
+ {
10554
+ // ![[ comment ]] , ![===[ comment]===]
10555
+ pattern: /(^|\s)!\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,
10556
+ lookbehind: true,
10557
+ greedy: true,
10558
+ inside: comment_inside
10559
+ }
10560
+ ],
10561
+ number: [
10562
+ {
10563
+ // basic base 10 integers 9, -9
10564
+ pattern: /(^|\s)[+-]?\d+(?=\s|$)/,
10565
+ lookbehind: true
10566
+ },
10567
+ {
10568
+ // base prefix integers 0b010 0o70 0xad 0d10 0XAD -0xa9
10569
+ pattern: /(^|\s)[+-]?0(?:b[01]+|o[0-7]+|d\d+|x[\dA-F]+)(?=\s|$)/i,
10570
+ lookbehind: true
10571
+ },
10572
+ {
10573
+ // fractional ratios 1/5 -1/5 and the literal float approximations 1/5. -1/5.
10574
+ pattern: /(^|\s)[+-]?\d+\/\d+\.?(?=\s|$)/,
10575
+ lookbehind: true
10576
+ },
10577
+ {
10578
+ // positive mixed numbers 23+1/5 +23+1/5
10579
+ pattern: /(^|\s)\+?\d+\+\d+\/\d+(?=\s|$)/,
10580
+ lookbehind: true
10581
+ },
10582
+ {
10583
+ // negative mixed numbers -23-1/5
10584
+ pattern: /(^|\s)-\d+-\d+\/\d+(?=\s|$)/,
10585
+ lookbehind: true
10586
+ },
10587
+ {
10588
+ // basic decimal floats -0.01 0. .0 .1 -.1 -1. -12.13 +12.13
10589
+ // and scientific notation with base 10 exponents 3e4 3e-4 .3e-4
10590
+ pattern:
10591
+ /(^|\s)[+-]?(?:\d*\.\d+|\d+\.\d*|\d+)(?:e[+-]?\d+)?(?=\s|$)/i,
10592
+ lookbehind: true
10593
+ },
10594
+ {
10595
+ // NAN literal syntax NAN: 80000deadbeef, NAN: a
10596
+ pattern: /(^|\s)NAN:\s+[\da-fA-F]+(?=\s|$)/,
10597
+ lookbehind: true
10598
+ },
10599
+ {
10600
+ /*
10601
+ base prefix floats 0x1.0p3 (8.0) 0b1.010p2 (5.0) 0x1.p1 0b1.11111111p11111...
10602
+ "The normalized hex form ±0x1.MMMMMMMMMMMMM[pP]±EEEE allows any floating-point number to be specified precisely.
10603
+ The values of MMMMMMMMMMMMM and EEEE map directly to the mantissa and exponent fields of the binary IEEE 754 representation."
10604
+ <https://docs.factorcode.org/content/article-syntax-floats.html>
10605
+ */
10606
+ pattern:
10607
+ /(^|\s)[+-]?0(?:b1\.[01]*|o1\.[0-7]*|d1\.\d*|x1\.[\dA-F]*)p\d+(?=\s|$)/i,
10608
+ lookbehind: true
10609
+ }
10610
+ ],
10611
+ // R/ regexp?\/\\/
10612
+ regexp: {
10613
+ pattern:
10614
+ /(^|\s)R\/\s(?:\\\S|[^\\/])*\/(?:[idmsr]*|[idmsr]+-[idmsr]+)(?=\s|$)/,
10615
+ lookbehind: true,
10616
+ alias: 'number',
10617
+ inside: {
10618
+ variable: /\\\S/,
10619
+ keyword: /[+?*\[\]^$(){}.|]/,
10620
+ operator: {
10621
+ pattern: /(\/)[idmsr]+(?:-[idmsr]+)?/,
10622
+ lookbehind: true
10623
+ }
10624
+ }
10625
+ },
10626
+ boolean: {
10627
+ pattern: /(^|\s)[tf](?=\s|$)/,
10628
+ lookbehind: true
10629
+ },
10630
+ // SBUF" asd", URL" ://...", P" /etc/"
10631
+ 'custom-string': {
10632
+ pattern: /(^|\s)[A-Z0-9\-]+"\s(?:\\\S|[^"\\])*"/,
10633
+ lookbehind: true,
10634
+ greedy: true,
10635
+ alias: 'string',
10636
+ inside: {
10637
+ number: /\\\S|%\w|\//
10638
+ }
10639
+ },
10640
+ 'multiline-string': [
10641
+ {
10642
+ // STRING: name \n content \n ; -> CONSTANT: name "content" (symbol)
10643
+ pattern: /(^|\s)STRING:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*;(?=\s|$)/,
10644
+ lookbehind: true,
10645
+ greedy: true,
10646
+ alias: 'string',
10647
+ inside: {
10648
+ number: string_inside.number,
10649
+ // trailing semicolon on its own line
10650
+ 'semicolon-or-setlocal': {
10651
+ pattern: /([\r\n][ \t]*);(?=\s|$)/,
10652
+ lookbehind: true,
10653
+ alias: 'function'
10654
+ }
10655
+ }
10656
+ },
10657
+ {
10658
+ // HEREDOC: marker \n content \n marker ; -> "content" (immediate)
10659
+ pattern: /(^|\s)HEREDOC:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*\S+(?=\s|$)/,
10660
+ lookbehind: true,
10661
+ greedy: true,
10662
+ alias: 'string',
10663
+ inside: string_inside
10664
+ },
10665
+ {
10666
+ // [[ string ]], [==[ string]==]
10667
+ pattern: /(^|\s)\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,
10668
+ lookbehind: true,
10669
+ greedy: true,
10670
+ alias: 'string',
10671
+ inside: string_inside
10672
+ }
10673
+ ],
10674
+ 'special-using': {
10675
+ pattern: /(^|\s)USING:(?:\s\S+)*(?=\s+;(?:\s|$))/,
10676
+ lookbehind: true,
10677
+ alias: 'function',
10678
+ inside: {
10679
+ // this is essentially a regex for vocab names, which i don't want to specify
10680
+ // but the USING: gets picked up as a vocab name
10681
+ string: {
10682
+ pattern: /(\s)[^:\s]+/,
10683
+ lookbehind: true
10684
+ }
10685
+ }
10686
+ },
10687
+ /* this description of stack effect literal syntax is not complete and not as specific as theoretically possible
10688
+ trying to do better is more work and regex-computation-time than it's worth though.
10689
+ - we'd like to have the "delimiter" parts of the stack effect [ (, --, and ) ] be a different (less-important or comment-like) colour to the stack effect contents
10690
+ - we'd like if nested stack effects were treated as such rather than just appearing flat (with `inside`)
10691
+ - we'd like if the following variable name conventions were recognised specifically:
10692
+ special row variables = ..a b..
10693
+ type and stack effect annotations end with a colon = ( quot: ( a: ( -- ) -- b ) -- x ), ( x: number -- )
10694
+ word throws unconditional error = *
10695
+ any other word-like variable name = a ? q' etc
10696
+ https://docs.factorcode.org/content/article-effects.html
10697
+ these are pretty complicated to highlight properly without a real parser, and therefore out of scope
10698
+ the old pattern, which may be later useful, was: (^|\s)(?:call|execute|eval)?\((?:\s+[^"\r\n\t ]\S*)*?\s+--(?:\s+[^"\n\t ]\S*)*?\s+\)(?=\s|$)
10699
+ */
10700
+ // current solution is not great
10701
+ 'stack-effect-delimiter': [
10702
+ {
10703
+ // opening parenthesis
10704
+ pattern: /(^|\s)(?:call|eval|execute)?\((?=\s)/,
10705
+ lookbehind: true,
10706
+ alias: 'operator'
10707
+ },
10708
+ {
10709
+ // middle --
10710
+ pattern: /(\s)--(?=\s)/,
10711
+ lookbehind: true,
10712
+ alias: 'operator'
10713
+ },
10714
+ {
10715
+ // closing parenthesis
10716
+ pattern: /(\s)\)(?=\s|$)/,
10717
+ lookbehind: true,
10718
+ alias: 'operator'
10719
+ }
10720
+ ],
10721
+ combinators: {
10722
+ pattern: null,
10723
+ lookbehind: true,
10724
+ alias: 'keyword'
10725
+ },
10726
+ 'kernel-builtin': {
10727
+ pattern: null,
10728
+ lookbehind: true,
10729
+ alias: 'variable'
10730
+ },
10731
+ 'sequences-builtin': {
10732
+ pattern: null,
10733
+ lookbehind: true,
10734
+ alias: 'variable'
10735
+ },
10736
+ 'math-builtin': {
10737
+ pattern: null,
10738
+ lookbehind: true,
10739
+ alias: 'variable'
10740
+ },
10741
+ 'constructor-word': {
10742
+ // <array> but not <=>
10743
+ pattern: /(^|\s)<(?!=+>|-+>)\S+>(?=\s|$)/,
10744
+ lookbehind: true,
10745
+ alias: 'keyword'
10746
+ },
10747
+ 'other-builtin-syntax': {
10748
+ pattern: null,
10749
+ lookbehind: true,
10750
+ alias: 'operator'
10751
+ },
10752
+ /*
10753
+ full list of supported word naming conventions: (the convention appears outside of the [brackets])
10754
+ set-[x]
10755
+ change-[x]
10756
+ with-[x]
10757
+ new-[x]
10758
+ >[string]
10759
+ [base]>
10760
+ [string]>[number]
10761
+ +[symbol]+
10762
+ [boolean-word]?
10763
+ ?[of]
10764
+ [slot-reader]>>
10765
+ >>[slot-setter]
10766
+ [slot-writer]<<
10767
+ ([implementation-detail])
10768
+ [mutater]!
10769
+ [variant]*
10770
+ [prettyprint].
10771
+ $[help-markup]
10772
+ <constructors>, SYNTAX:, etc are supported by their own patterns.
10773
+ `with` and `new` from `kernel` are their own builtins.
10774
+ see <https://docs.factorcode.org/content/article-conventions.html>
10775
+ */
10776
+ 'conventionally-named-word': {
10777
+ pattern:
10778
+ /(^|\s)(?!")(?:(?:change|new|set|with)-\S+|\$\S+|>[^>\s]+|[^:>\s]+>|[^>\s]+>[^>\s]+|\+[^+\s]+\+|[^?\s]+\?|\?[^?\s]+|[^>\s]+>>|>>[^>\s]+|[^<\s]+<<|\([^()\s]+\)|[^!\s]+!|[^*\s]\S*\*|[^.\s]\S*\.)(?=\s|$)/,
10779
+ lookbehind: true,
10780
+ alias: 'keyword'
10781
+ },
10782
+ 'colon-syntax': {
10783
+ pattern: /(^|\s)(?:[A-Z0-9\-]+#?)?:{1,2}\s+(?:;\S+|(?!;)\S+)(?=\s|$)/,
10784
+ lookbehind: true,
10785
+ greedy: true,
10786
+ alias: 'function'
10787
+ },
10788
+ 'semicolon-or-setlocal': {
10789
+ pattern: /(\s)(?:;|:>)(?=\s|$)/,
10790
+ lookbehind: true,
10791
+ alias: 'function'
10792
+ },
10793
+ // do not highlight leading } or trailing X{ at the begin/end of the file as it's invalid syntax
10794
+ 'curly-brace-literal-delimiter': [
10795
+ {
10796
+ // opening
10797
+ pattern: /(^|\s)[a-z]*\{(?=\s)/i,
10798
+ lookbehind: true,
10799
+ alias: 'operator'
10800
+ },
10801
+ {
10802
+ // closing
10803
+ pattern: /(\s)\}(?=\s|$)/,
10804
+ lookbehind: true,
10805
+ alias: 'operator'
10806
+ }
10807
+ ],
10808
+ // do not highlight leading ] or trailing [ at the begin/end of the file as it's invalid syntax
10809
+ 'quotation-delimiter': [
10810
+ {
10811
+ // opening
10812
+ pattern: /(^|\s)\[(?=\s)/,
10813
+ lookbehind: true,
10814
+ alias: 'operator'
10815
+ },
10816
+ {
10817
+ // closing
10818
+ pattern: /(\s)\](?=\s|$)/,
10819
+ lookbehind: true,
10820
+ alias: 'operator'
10821
+ }
10822
+ ],
10823
+ 'normal-word': {
10824
+ pattern: /(^|\s)[^"\s]\S*(?=\s|$)/,
10825
+ lookbehind: true
10826
+ },
10827
+ /*
10828
+ basic first-class string "a"
10829
+ with escaped double-quote "a\""
10830
+ escaped backslash "\\"
10831
+ and general escapes since Factor has so many "\N"
10832
+ syntax that works in the reference implementation that isn't fully
10833
+ supported because it's an implementation detail:
10834
+ "string 1""string 2" -> 2 strings (works anyway)
10835
+ "string"5 -> string, 5
10836
+ "string"[ ] -> string, quotation
10837
+ { "a"} -> array<string>
10838
+ the rest of those examples all properly recognise the string, but not
10839
+ the other object (number, quotation, etc)
10840
+ this is fine for a regex-only implementation.
10841
+ */
10842
+ string: {
10843
+ pattern: /"(?:\\\S|[^"\\])*"/,
10844
+ greedy: true,
10845
+ inside: string_inside
10846
+ }
10847
+ };
10848
+ var escape = function (str) {
10849
+ return (str + '').replace(/([.?*+\^$\[\]\\(){}|\-])/g, '\\$1')
10850
+ };
10851
+ var arrToWordsRegExp = function (arr) {
10852
+ return new RegExp('(^|\\s)(?:' + arr.map(escape).join('|') + ')(?=\\s|$)')
10853
+ };
10854
+ var builtins = {
10855
+ 'kernel-builtin': [
10856
+ 'or',
10857
+ '2nipd',
10858
+ '4drop',
10859
+ 'tuck',
10860
+ 'wrapper',
10861
+ 'nip',
10862
+ 'wrapper?',
10863
+ 'callstack>array',
10864
+ 'die',
10865
+ 'dupd',
10866
+ 'callstack',
10867
+ 'callstack?',
10868
+ '3dup',
10869
+ 'hashcode',
10870
+ 'pick',
10871
+ '4nip',
10872
+ 'build',
10873
+ '>boolean',
10874
+ 'nipd',
10875
+ 'clone',
10876
+ '5nip',
10877
+ 'eq?',
10878
+ '?',
10879
+ '=',
10880
+ 'swapd',
10881
+ '2over',
10882
+ 'clear',
10883
+ '2dup',
10884
+ 'get-retainstack',
10885
+ 'not',
10886
+ 'tuple?',
10887
+ 'dup',
10888
+ '3nipd',
10889
+ 'call',
10890
+ '-rotd',
10891
+ 'object',
10892
+ 'drop',
10893
+ 'assert=',
10894
+ 'assert?',
10895
+ '-rot',
10896
+ 'execute',
10897
+ 'boa',
10898
+ 'get-callstack',
10899
+ 'curried?',
10900
+ '3drop',
10901
+ 'pickd',
10902
+ 'overd',
10903
+ 'over',
10904
+ 'roll',
10905
+ '3nip',
10906
+ 'swap',
10907
+ 'and',
10908
+ '2nip',
10909
+ 'rotd',
10910
+ 'throw',
10911
+ '(clone)',
10912
+ 'hashcode*',
10913
+ 'spin',
10914
+ 'reach',
10915
+ '4dup',
10916
+ 'equal?',
10917
+ 'get-datastack',
10918
+ 'assert',
10919
+ '2drop',
10920
+ '<wrapper>',
10921
+ 'boolean?',
10922
+ 'identity-hashcode',
10923
+ 'identity-tuple?',
10924
+ 'null',
10925
+ 'composed?',
10926
+ 'new',
10927
+ '5drop',
10928
+ 'rot',
10929
+ '-roll',
10930
+ 'xor',
10931
+ 'identity-tuple',
10932
+ 'boolean'
10933
+ ],
10934
+ 'other-builtin-syntax': [
10935
+ // syntax
10936
+ '=======',
10937
+ 'recursive',
10938
+ 'flushable',
10939
+ '>>',
10940
+ '<<<<<<',
10941
+ 'M\\',
10942
+ 'B',
10943
+ 'PRIVATE>',
10944
+ '\\',
10945
+ '======',
10946
+ 'final',
10947
+ 'inline',
10948
+ 'delimiter',
10949
+ 'deprecated',
10950
+ '<PRIVATE',
10951
+ '>>>>>>',
10952
+ '<<<<<<<',
10953
+ 'parse-complex',
10954
+ 'malformed-complex',
10955
+ 'read-only',
10956
+ '>>>>>>>',
10957
+ 'call-next-method',
10958
+ '<<',
10959
+ 'foldable', // literals
10960
+ '$',
10961
+ '$[',
10962
+ '${'
10963
+ ],
10964
+ 'sequences-builtin': [
10965
+ 'member-eq?',
10966
+ 'mismatch',
10967
+ 'append',
10968
+ 'assert-sequence=',
10969
+ 'longer',
10970
+ 'repetition',
10971
+ 'clone-like',
10972
+ '3sequence',
10973
+ 'assert-sequence?',
10974
+ 'last-index-from',
10975
+ 'reversed',
10976
+ 'index-from',
10977
+ 'cut*',
10978
+ 'pad-tail',
10979
+ 'join-as',
10980
+ 'remove-eq!',
10981
+ 'concat-as',
10982
+ 'but-last',
10983
+ 'snip',
10984
+ 'nths',
10985
+ 'nth',
10986
+ 'sequence',
10987
+ 'longest',
10988
+ 'slice?',
10989
+ '<slice>',
10990
+ 'remove-nth',
10991
+ 'tail-slice',
10992
+ 'empty?',
10993
+ 'tail*',
10994
+ 'member?',
10995
+ 'virtual-sequence?',
10996
+ 'set-length',
10997
+ 'drop-prefix',
10998
+ 'iota',
10999
+ 'unclip',
11000
+ 'bounds-error?',
11001
+ 'unclip-last-slice',
11002
+ 'non-negative-integer-expected',
11003
+ 'non-negative-integer-expected?',
11004
+ 'midpoint@',
11005
+ 'longer?',
11006
+ '?set-nth',
11007
+ '?first',
11008
+ 'rest-slice',
11009
+ 'prepend-as',
11010
+ 'prepend',
11011
+ 'fourth',
11012
+ 'sift',
11013
+ 'subseq-start',
11014
+ 'new-sequence',
11015
+ '?last',
11016
+ 'like',
11017
+ 'first4',
11018
+ '1sequence',
11019
+ 'reverse',
11020
+ 'slice',
11021
+ 'virtual@',
11022
+ 'repetition?',
11023
+ 'set-last',
11024
+ 'index',
11025
+ '4sequence',
11026
+ 'max-length',
11027
+ 'set-second',
11028
+ 'immutable-sequence',
11029
+ 'first2',
11030
+ 'first3',
11031
+ 'supremum',
11032
+ 'unclip-slice',
11033
+ 'suffix!',
11034
+ 'insert-nth',
11035
+ 'tail',
11036
+ '3append',
11037
+ 'short',
11038
+ 'suffix',
11039
+ 'concat',
11040
+ 'flip',
11041
+ 'immutable?',
11042
+ 'reverse!',
11043
+ '2sequence',
11044
+ 'sum',
11045
+ 'delete-all',
11046
+ 'indices',
11047
+ 'snip-slice',
11048
+ '<iota>',
11049
+ 'check-slice',
11050
+ 'sequence?',
11051
+ 'head',
11052
+ 'append-as',
11053
+ 'halves',
11054
+ 'sequence=',
11055
+ 'collapse-slice',
11056
+ '?second',
11057
+ 'slice-error?',
11058
+ 'product',
11059
+ 'bounds-check?',
11060
+ 'bounds-check',
11061
+ 'immutable',
11062
+ 'virtual-exemplar',
11063
+ 'harvest',
11064
+ 'remove',
11065
+ 'pad-head',
11066
+ 'last',
11067
+ 'set-fourth',
11068
+ 'cartesian-product',
11069
+ 'remove-eq',
11070
+ 'shorten',
11071
+ 'shorter',
11072
+ 'reversed?',
11073
+ 'shorter?',
11074
+ 'shortest',
11075
+ 'head-slice',
11076
+ 'pop*',
11077
+ 'tail-slice*',
11078
+ 'but-last-slice',
11079
+ 'iota?',
11080
+ 'append!',
11081
+ 'cut-slice',
11082
+ 'new-resizable',
11083
+ 'head-slice*',
11084
+ 'sequence-hashcode',
11085
+ 'pop',
11086
+ 'set-nth',
11087
+ '?nth',
11088
+ 'second',
11089
+ 'join',
11090
+ 'immutable-sequence?',
11091
+ '<reversed>',
11092
+ '3append-as',
11093
+ 'virtual-sequence',
11094
+ 'subseq?',
11095
+ 'remove-nth!',
11096
+ 'length',
11097
+ 'last-index',
11098
+ 'lengthen',
11099
+ 'assert-sequence',
11100
+ 'copy',
11101
+ 'move',
11102
+ 'third',
11103
+ 'first',
11104
+ 'tail?',
11105
+ 'set-first',
11106
+ 'prefix',
11107
+ 'bounds-error',
11108
+ '<repetition>',
11109
+ 'exchange',
11110
+ 'surround',
11111
+ 'cut',
11112
+ 'min-length',
11113
+ 'set-third',
11114
+ 'push-all',
11115
+ 'head?',
11116
+ 'subseq-start-from',
11117
+ 'delete-slice',
11118
+ 'rest',
11119
+ 'sum-lengths',
11120
+ 'head*',
11121
+ 'infimum',
11122
+ 'remove!',
11123
+ 'glue',
11124
+ 'slice-error',
11125
+ 'subseq',
11126
+ 'push',
11127
+ 'replace-slice',
11128
+ 'subseq-as',
11129
+ 'unclip-last'
11130
+ ],
11131
+ 'math-builtin': [
11132
+ 'number=',
11133
+ 'next-power-of-2',
11134
+ '?1+',
11135
+ 'fp-special?',
11136
+ 'imaginary-part',
11137
+ 'float>bits',
11138
+ 'number?',
11139
+ 'fp-infinity?',
11140
+ 'bignum?',
11141
+ 'fp-snan?',
11142
+ 'denominator',
11143
+ 'gcd',
11144
+ '*',
11145
+ '+',
11146
+ 'fp-bitwise=',
11147
+ '-',
11148
+ 'u>=',
11149
+ '/',
11150
+ '>=',
11151
+ 'bitand',
11152
+ 'power-of-2?',
11153
+ 'log2-expects-positive',
11154
+ 'neg?',
11155
+ '<',
11156
+ 'log2',
11157
+ '>',
11158
+ 'integer?',
11159
+ 'number',
11160
+ 'bits>double',
11161
+ '2/',
11162
+ 'zero?',
11163
+ 'bits>float',
11164
+ 'float?',
11165
+ 'shift',
11166
+ 'ratio?',
11167
+ 'rect>',
11168
+ 'even?',
11169
+ 'ratio',
11170
+ 'fp-sign',
11171
+ 'bitnot',
11172
+ '>fixnum',
11173
+ 'complex?',
11174
+ '/i',
11175
+ 'integer>fixnum',
11176
+ '/f',
11177
+ 'sgn',
11178
+ '>bignum',
11179
+ 'next-float',
11180
+ 'u<',
11181
+ 'u>',
11182
+ 'mod',
11183
+ 'recip',
11184
+ 'rational',
11185
+ '>float',
11186
+ '2^',
11187
+ 'integer',
11188
+ 'fixnum?',
11189
+ 'neg',
11190
+ 'fixnum',
11191
+ 'sq',
11192
+ 'bignum',
11193
+ '>rect',
11194
+ 'bit?',
11195
+ 'fp-qnan?',
11196
+ 'simple-gcd',
11197
+ 'complex',
11198
+ '<fp-nan>',
11199
+ 'real',
11200
+ '>fraction',
11201
+ 'double>bits',
11202
+ 'bitor',
11203
+ 'rem',
11204
+ 'fp-nan-payload',
11205
+ 'real-part',
11206
+ 'log2-expects-positive?',
11207
+ 'prev-float',
11208
+ 'align',
11209
+ 'unordered?',
11210
+ 'float',
11211
+ 'fp-nan?',
11212
+ 'abs',
11213
+ 'bitxor',
11214
+ 'integer>fixnum-strict',
11215
+ 'u<=',
11216
+ 'odd?',
11217
+ '<=',
11218
+ '/mod',
11219
+ '>integer',
11220
+ 'real?',
11221
+ 'rational?',
11222
+ 'numerator'
11223
+ ] // that's all for now
11224
+ };
11225
+ Object.keys(builtins).forEach(function (k) {
11226
+ factor[k].pattern = arrToWordsRegExp(builtins[k]);
11227
+ });
11228
+ var combinators = [
11229
+ // kernel
11230
+ '2bi',
11231
+ 'while',
11232
+ '2tri',
11233
+ 'bi*',
11234
+ '4dip',
11235
+ 'both?',
11236
+ 'same?',
11237
+ 'tri@',
11238
+ 'curry',
11239
+ 'prepose',
11240
+ '3bi',
11241
+ '?if',
11242
+ 'tri*',
11243
+ '2keep',
11244
+ '3keep',
11245
+ 'curried',
11246
+ '2keepd',
11247
+ 'when',
11248
+ '2bi*',
11249
+ '2tri*',
11250
+ '4keep',
11251
+ 'bi@',
11252
+ 'keepdd',
11253
+ 'do',
11254
+ 'unless*',
11255
+ 'tri-curry',
11256
+ 'if*',
11257
+ 'loop',
11258
+ 'bi-curry*',
11259
+ 'when*',
11260
+ '2bi@',
11261
+ '2tri@',
11262
+ 'with',
11263
+ '2with',
11264
+ 'either?',
11265
+ 'bi',
11266
+ 'until',
11267
+ '3dip',
11268
+ '3curry',
11269
+ 'tri-curry*',
11270
+ 'tri-curry@',
11271
+ 'bi-curry',
11272
+ 'keepd',
11273
+ 'compose',
11274
+ '2dip',
11275
+ 'if',
11276
+ '3tri',
11277
+ 'unless',
11278
+ 'tuple',
11279
+ 'keep',
11280
+ '2curry',
11281
+ 'tri',
11282
+ 'most',
11283
+ 'while*',
11284
+ 'dip',
11285
+ 'composed',
11286
+ 'bi-curry@', // sequences
11287
+ 'find-last-from',
11288
+ 'trim-head-slice',
11289
+ 'map-as',
11290
+ 'each-from',
11291
+ 'none?',
11292
+ 'trim-tail',
11293
+ 'partition',
11294
+ 'if-empty',
11295
+ 'accumulate*',
11296
+ 'reject!',
11297
+ 'find-from',
11298
+ 'accumulate-as',
11299
+ 'collector-for-as',
11300
+ 'reject',
11301
+ 'map',
11302
+ 'map-sum',
11303
+ 'accumulate!',
11304
+ '2each-from',
11305
+ 'follow',
11306
+ 'supremum-by',
11307
+ 'map!',
11308
+ 'unless-empty',
11309
+ 'collector',
11310
+ 'padding',
11311
+ 'reduce-index',
11312
+ 'replicate-as',
11313
+ 'infimum-by',
11314
+ 'trim-tail-slice',
11315
+ 'count',
11316
+ 'find-index',
11317
+ 'filter',
11318
+ 'accumulate*!',
11319
+ 'reject-as',
11320
+ 'map-integers',
11321
+ 'map-find',
11322
+ 'reduce',
11323
+ 'selector',
11324
+ 'interleave',
11325
+ '2map',
11326
+ 'filter-as',
11327
+ 'binary-reduce',
11328
+ 'map-index-as',
11329
+ 'find',
11330
+ 'produce',
11331
+ 'filter!',
11332
+ 'replicate',
11333
+ 'cartesian-map',
11334
+ 'cartesian-each',
11335
+ 'find-index-from',
11336
+ 'map-find-last',
11337
+ '3map-as',
11338
+ '3map',
11339
+ 'find-last',
11340
+ 'selector-as',
11341
+ '2map-as',
11342
+ '2map-reduce',
11343
+ 'accumulate',
11344
+ 'each',
11345
+ 'each-index',
11346
+ 'accumulate*-as',
11347
+ 'when-empty',
11348
+ 'all?',
11349
+ 'collector-as',
11350
+ 'push-either',
11351
+ 'new-like',
11352
+ 'collector-for',
11353
+ '2selector',
11354
+ 'push-if',
11355
+ '2all?',
11356
+ 'map-reduce',
11357
+ '3each',
11358
+ 'any?',
11359
+ 'trim-slice',
11360
+ '2reduce',
11361
+ 'change-nth',
11362
+ 'produce-as',
11363
+ '2each',
11364
+ 'trim',
11365
+ 'trim-head',
11366
+ 'cartesian-find',
11367
+ 'map-index', // math
11368
+ 'if-zero',
11369
+ 'each-integer',
11370
+ 'unless-zero',
11371
+ '(find-integer)',
11372
+ 'when-zero',
11373
+ 'find-last-integer',
11374
+ '(all-integers?)',
11375
+ 'times',
11376
+ '(each-integer)',
11377
+ 'find-integer',
11378
+ 'all-integers?', // math.combinators
11379
+ 'unless-negative',
11380
+ 'if-positive',
11381
+ 'when-positive',
11382
+ 'when-negative',
11383
+ 'unless-positive',
11384
+ 'if-negative', // combinators
11385
+ 'case',
11386
+ '2cleave',
11387
+ 'cond>quot',
11388
+ 'case>quot',
11389
+ '3cleave',
11390
+ 'wrong-values',
11391
+ 'to-fixed-point',
11392
+ 'alist>quot',
11393
+ 'cond',
11394
+ 'cleave',
11395
+ 'call-effect',
11396
+ 'recursive-hashcode',
11397
+ 'spread',
11398
+ 'deep-spread>quot', // combinators.short-circuit
11399
+ '2||',
11400
+ '0||',
11401
+ 'n||',
11402
+ '0&&',
11403
+ '2&&',
11404
+ '3||',
11405
+ '1||',
11406
+ '1&&',
11407
+ 'n&&',
11408
+ '3&&', // combinators.smart
11409
+ 'smart-unless*',
11410
+ 'keep-inputs',
11411
+ 'reduce-outputs',
11412
+ 'smart-when*',
11413
+ 'cleave>array',
11414
+ 'smart-with',
11415
+ 'smart-apply',
11416
+ 'smart-if',
11417
+ 'inputs/outputs',
11418
+ 'output>sequence-n',
11419
+ 'map-outputs',
11420
+ 'map-reduce-outputs',
11421
+ 'dropping',
11422
+ 'output>array',
11423
+ 'smart-map-reduce',
11424
+ 'smart-2map-reduce',
11425
+ 'output>array-n',
11426
+ 'nullary',
11427
+ 'input<sequence',
11428
+ 'append-outputs',
11429
+ 'drop-inputs',
11430
+ 'inputs',
11431
+ 'smart-2reduce',
11432
+ 'drop-outputs',
11433
+ 'smart-reduce',
11434
+ 'preserving',
11435
+ 'smart-when',
11436
+ 'outputs',
11437
+ 'append-outputs-as',
11438
+ 'smart-unless',
11439
+ 'smart-if*',
11440
+ 'sum-outputs',
11441
+ 'input<sequence-unsafe',
11442
+ 'output>sequence' // tafn
11443
+ ];
11444
+ factor.combinators.pattern = arrToWordsRegExp(combinators);
11445
+ Prism.languages.factor = factor;
11446
+ })(Prism);
11447
+ }
11448
+ return factor_1;
11354
11449
  }
11355
11450
 
11356
- var _false = $false;
11357
- $false.displayName = '$false';
11358
- $false.aliases = [];
11359
- function $false(Prism) {
11451
+ var _false;
11452
+ var hasRequired_false;
11453
+
11454
+ function require_false () {
11455
+ if (hasRequired_false) return _false;
11456
+ hasRequired_false = 1;
11457
+
11458
+ _false = $false;
11459
+ $false.displayName = '$false';
11460
+ $false.aliases = [];
11461
+ function $false(Prism) {
11360
11462
  (function (Prism) {
11361
- /**
11362
- * Based on the manual by Wouter van Oortmerssen.
11363
- *
11364
- * @see {@link https://github.com/PrismJS/prism/issues/2801#issue-829717504}
11365
- */
11366
- Prism.languages['false'] = {
11367
- comment: {
11368
- pattern: /\{[^}]*\}/
11369
- },
11370
- string: {
11371
- pattern: /"[^"]*"/,
11372
- greedy: true
11373
- },
11374
- 'character-code': {
11375
- pattern: /'(?:[^\r]|\r\n?)/,
11376
- alias: 'number'
11377
- },
11378
- 'assembler-code': {
11379
- pattern: /\d+`/,
11380
- alias: 'important'
11381
- },
11382
- number: /\d+/,
11383
- operator: /[-!#$%&'*+,./:;=>?@\\^_`|~ßø]/,
11384
- punctuation: /\[|\]/,
11385
- variable: /[a-z]/,
11386
- 'non-standard': {
11387
- pattern: /[()<BDO®]/,
11388
- alias: 'bold'
11389
- }
11390
- };
11391
- })(Prism);
11463
+ /**
11464
+ * Based on the manual by Wouter van Oortmerssen.
11465
+ *
11466
+ * @see {@link https://github.com/PrismJS/prism/issues/2801#issue-829717504}
11467
+ */
11468
+ Prism.languages['false'] = {
11469
+ comment: {
11470
+ pattern: /\{[^}]*\}/
11471
+ },
11472
+ string: {
11473
+ pattern: /"[^"]*"/,
11474
+ greedy: true
11475
+ },
11476
+ 'character-code': {
11477
+ pattern: /'(?:[^\r]|\r\n?)/,
11478
+ alias: 'number'
11479
+ },
11480
+ 'assembler-code': {
11481
+ pattern: /\d+`/,
11482
+ alias: 'important'
11483
+ },
11484
+ number: /\d+/,
11485
+ operator: /[-!#$%&'*+,./:;=>?@\\^_`|~ßø]/,
11486
+ punctuation: /\[|\]/,
11487
+ variable: /[a-z]/,
11488
+ 'non-standard': {
11489
+ pattern: /[()<BDO®]/,
11490
+ alias: 'bold'
11491
+ }
11492
+ };
11493
+ })(Prism);
11494
+ }
11495
+ return _false;
11392
11496
  }
11393
11497
 
11394
- var firestoreSecurityRules_1 = firestoreSecurityRules;
11395
- firestoreSecurityRules.displayName = 'firestoreSecurityRules';
11396
- firestoreSecurityRules.aliases = [];
11397
- function firestoreSecurityRules(Prism) {
11398
- Prism.languages['firestore-security-rules'] = Prism.languages.extend(
11399
- 'clike',
11400
- {
11401
- comment: /\/\/.*/,
11402
- keyword:
11403
- /\b(?:allow|function|if|match|null|return|rules_version|service)\b/,
11404
- operator: /&&|\|\||[<>!=]=?|[-+*/%]|\b(?:in|is)\b/
11405
- }
11406
- );
11407
- delete Prism.languages['firestore-security-rules']['class-name'];
11408
- Prism.languages.insertBefore('firestore-security-rules', 'keyword', {
11409
- path: {
11410
- pattern:
11411
- /(^|[\s(),])(?:\/(?:[\w\xA0-\uFFFF]+|\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)))+/,
11412
- lookbehind: true,
11413
- greedy: true,
11414
- inside: {
11415
- variable: {
11416
- pattern: /\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)/,
11417
- inside: {
11418
- operator: /=/,
11419
- keyword: /\*\*/,
11420
- punctuation: /[.$(){}]/
11421
- }
11422
- },
11423
- punctuation: /\//
11424
- }
11425
- },
11426
- method: {
11427
- // to make the pattern shorter, the actual method names are omitted
11428
- pattern: /(\ballow\s+)[a-z]+(?:\s*,\s*[a-z]+)*(?=\s*[:;])/,
11429
- lookbehind: true,
11430
- alias: 'builtin',
11431
- inside: {
11432
- punctuation: /,/
11433
- }
11434
- }
11435
- });
11498
+ var firestoreSecurityRules_1;
11499
+ var hasRequiredFirestoreSecurityRules;
11500
+
11501
+ function requireFirestoreSecurityRules () {
11502
+ if (hasRequiredFirestoreSecurityRules) return firestoreSecurityRules_1;
11503
+ hasRequiredFirestoreSecurityRules = 1;
11504
+
11505
+ firestoreSecurityRules_1 = firestoreSecurityRules;
11506
+ firestoreSecurityRules.displayName = 'firestoreSecurityRules';
11507
+ firestoreSecurityRules.aliases = [];
11508
+ function firestoreSecurityRules(Prism) {
11509
+ Prism.languages['firestore-security-rules'] = Prism.languages.extend(
11510
+ 'clike',
11511
+ {
11512
+ comment: /\/\/.*/,
11513
+ keyword:
11514
+ /\b(?:allow|function|if|match|null|return|rules_version|service)\b/,
11515
+ operator: /&&|\|\||[<>!=]=?|[-+*/%]|\b(?:in|is)\b/
11516
+ }
11517
+ );
11518
+ delete Prism.languages['firestore-security-rules']['class-name'];
11519
+ Prism.languages.insertBefore('firestore-security-rules', 'keyword', {
11520
+ path: {
11521
+ pattern:
11522
+ /(^|[\s(),])(?:\/(?:[\w\xA0-\uFFFF]+|\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)))+/,
11523
+ lookbehind: true,
11524
+ greedy: true,
11525
+ inside: {
11526
+ variable: {
11527
+ pattern: /\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)/,
11528
+ inside: {
11529
+ operator: /=/,
11530
+ keyword: /\*\*/,
11531
+ punctuation: /[.$(){}]/
11532
+ }
11533
+ },
11534
+ punctuation: /\//
11535
+ }
11536
+ },
11537
+ method: {
11538
+ // to make the pattern shorter, the actual method names are omitted
11539
+ pattern: /(\ballow\s+)[a-z]+(?:\s*,\s*[a-z]+)*(?=\s*[:;])/,
11540
+ lookbehind: true,
11541
+ alias: 'builtin',
11542
+ inside: {
11543
+ punctuation: /,/
11544
+ }
11545
+ }
11546
+ });
11547
+ }
11548
+ return firestoreSecurityRules_1;
11436
11549
  }
11437
11550
 
11438
- var flow_1 = flow;
11439
- flow.displayName = 'flow';
11440
- flow.aliases = [];
11441
- function flow(Prism) {
11551
+ var flow_1;
11552
+ var hasRequiredFlow;
11553
+
11554
+ function requireFlow () {
11555
+ if (hasRequiredFlow) return flow_1;
11556
+ hasRequiredFlow = 1;
11557
+
11558
+ flow_1 = flow;
11559
+ flow.displayName = 'flow';
11560
+ flow.aliases = [];
11561
+ function flow(Prism) {
11442
11562
  (function (Prism) {
11443
- Prism.languages.flow = Prism.languages.extend('javascript', {});
11444
- Prism.languages.insertBefore('flow', 'keyword', {
11445
- type: [
11446
- {
11447
- pattern:
11448
- /\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|any|mixed|null|void)\b/,
11449
- alias: 'tag'
11450
- }
11451
- ]
11452
- });
11453
- Prism.languages.flow['function-variable'].pattern =
11454
- /(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i;
11455
- delete Prism.languages.flow['parameter'];
11456
- Prism.languages.insertBefore('flow', 'operator', {
11457
- 'flow-punctuation': {
11458
- pattern: /\{\||\|\}/,
11459
- alias: 'punctuation'
11460
- }
11461
- });
11462
- if (!Array.isArray(Prism.languages.flow.keyword)) {
11463
- Prism.languages.flow.keyword = [Prism.languages.flow.keyword];
11464
- }
11465
- Prism.languages.flow.keyword.unshift(
11466
- {
11467
- pattern: /(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,
11468
- lookbehind: true
11469
- },
11470
- {
11471
- pattern:
11472
- /(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,
11473
- lookbehind: true
11474
- }
11475
- );
11476
- })(Prism);
11563
+ Prism.languages.flow = Prism.languages.extend('javascript', {});
11564
+ Prism.languages.insertBefore('flow', 'keyword', {
11565
+ type: [
11566
+ {
11567
+ pattern:
11568
+ /\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|any|mixed|null|void)\b/,
11569
+ alias: 'tag'
11570
+ }
11571
+ ]
11572
+ });
11573
+ Prism.languages.flow['function-variable'].pattern =
11574
+ /(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i;
11575
+ delete Prism.languages.flow['parameter'];
11576
+ Prism.languages.insertBefore('flow', 'operator', {
11577
+ 'flow-punctuation': {
11578
+ pattern: /\{\||\|\}/,
11579
+ alias: 'punctuation'
11580
+ }
11581
+ });
11582
+ if (!Array.isArray(Prism.languages.flow.keyword)) {
11583
+ Prism.languages.flow.keyword = [Prism.languages.flow.keyword];
11584
+ }
11585
+ Prism.languages.flow.keyword.unshift(
11586
+ {
11587
+ pattern: /(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,
11588
+ lookbehind: true
11589
+ },
11590
+ {
11591
+ pattern:
11592
+ /(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,
11593
+ lookbehind: true
11594
+ }
11595
+ );
11596
+ })(Prism);
11597
+ }
11598
+ return flow_1;
11477
11599
  }
11478
11600
 
11479
- var fortran_1 = fortran;
11480
- fortran.displayName = 'fortran';
11481
- fortran.aliases = [];
11482
- function fortran(Prism) {
11483
- Prism.languages.fortran = {
11484
- 'quoted-number': {
11485
- pattern: /[BOZ](['"])[A-F0-9]+\1/i,
11486
- alias: 'number'
11487
- },
11488
- string: {
11489
- pattern:
11490
- /(?:\b\w+_)?(['"])(?:\1\1|&(?:\r\n?|\n)(?:[ \t]*!.*(?:\r\n?|\n)|(?![ \t]*!))|(?!\1).)*(?:\1|&)/,
11491
- inside: {
11492
- comment: {
11493
- pattern: /(&(?:\r\n?|\n)\s*)!.*/,
11494
- lookbehind: true
11495
- }
11496
- }
11497
- },
11498
- comment: {
11499
- pattern: /!.*/,
11500
- greedy: true
11501
- },
11502
- boolean: /\.(?:FALSE|TRUE)\.(?:_\w+)?/i,
11503
- number: /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[ED][+-]?\d+)?(?:_\w+)?/i,
11504
- keyword: [
11505
- // Types
11506
- /\b(?:CHARACTER|COMPLEX|DOUBLE ?PRECISION|INTEGER|LOGICAL|REAL)\b/i, // END statements
11507
- /\b(?:END ?)?(?:BLOCK ?DATA|DO|FILE|FORALL|FUNCTION|IF|INTERFACE|MODULE(?! PROCEDURE)|PROGRAM|SELECT|SUBROUTINE|TYPE|WHERE)\b/i, // Statements
11508
- /\b(?:ALLOCATABLE|ALLOCATE|BACKSPACE|CALL|CASE|CLOSE|COMMON|CONTAINS|CONTINUE|CYCLE|DATA|DEALLOCATE|DIMENSION|DO|END|EQUIVALENCE|EXIT|EXTERNAL|FORMAT|GO ?TO|IMPLICIT(?: NONE)?|INQUIRE|INTENT|INTRINSIC|MODULE PROCEDURE|NAMELIST|NULLIFY|OPEN|OPTIONAL|PARAMETER|POINTER|PRINT|PRIVATE|PUBLIC|READ|RETURN|REWIND|SAVE|SELECT|STOP|TARGET|WHILE|WRITE)\b/i, // Others
11509
- /\b(?:ASSIGNMENT|DEFAULT|ELEMENTAL|ELSE|ELSEIF|ELSEWHERE|ENTRY|IN|INCLUDE|INOUT|KIND|NULL|ONLY|OPERATOR|OUT|PURE|RECURSIVE|RESULT|SEQUENCE|STAT|THEN|USE)\b/i
11510
- ],
11511
- operator: [
11512
- /\*\*|\/\/|=>|[=\/]=|[<>]=?|::|[+\-*=%]|\.[A-Z]+\./i,
11513
- {
11514
- // Use lookbehind to prevent confusion with (/ /)
11515
- pattern: /(^|(?!\().)\/(?!\))/,
11516
- lookbehind: true
11517
- }
11518
- ],
11519
- punctuation: /\(\/|\/\)|[(),;:&]/
11520
- };
11521
- }
11601
+ var fortran_1;
11602
+ var hasRequiredFortran;
11522
11603
 
11523
- var fsharp_1 = fsharp;
11524
- fsharp.displayName = 'fsharp';
11525
- fsharp.aliases = [];
11526
- function fsharp(Prism) {
11527
- Prism.languages.fsharp = Prism.languages.extend('clike', {
11528
- comment: [
11529
- {
11530
- pattern: /(^|[^\\])\(\*(?!\))[\s\S]*?\*\)/,
11531
- lookbehind: true,
11532
- greedy: true
11533
- },
11534
- {
11535
- pattern: /(^|[^\\:])\/\/.*/,
11536
- lookbehind: true,
11537
- greedy: true
11538
- }
11539
- ],
11540
- string: {
11541
- pattern: /(?:"""[\s\S]*?"""|@"(?:""|[^"])*"|"(?:\\[\s\S]|[^\\"])*")B?/,
11542
- greedy: true
11543
- },
11544
- 'class-name': {
11545
- pattern:
11546
- /(\b(?:exception|inherit|interface|new|of|type)\s+|\w\s*:\s*|\s:\??>\s*)[.\w]+\b(?:\s*(?:->|\*)\s*[.\w]+\b)*(?!\s*[:.])/,
11547
- lookbehind: true,
11548
- inside: {
11549
- operator: /->|\*/,
11550
- punctuation: /\./
11551
- }
11552
- },
11553
- keyword:
11554
- /\b(?:let|return|use|yield)(?:!\B|\b)|\b(?:abstract|and|as|asr|assert|atomic|base|begin|break|checked|class|component|const|constraint|constructor|continue|default|delegate|do|done|downcast|downto|eager|elif|else|end|event|exception|extern|external|false|finally|fixed|for|fun|function|functor|global|if|in|include|inherit|inline|interface|internal|land|lazy|lor|lsl|lsr|lxor|match|member|method|mixin|mod|module|mutable|namespace|new|not|null|object|of|open|or|override|parallel|private|process|protected|public|pure|rec|sealed|select|sig|static|struct|tailcall|then|to|trait|true|try|type|upcast|val|virtual|void|volatile|when|while|with)\b/,
11555
- number: [
11556
- /\b0x[\da-fA-F]+(?:LF|lf|un)?\b/,
11557
- /\b0b[01]+(?:uy|y)?\b/,
11558
- /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[fm]|e[+-]?\d+)?\b/i,
11559
- /\b\d+(?:[IlLsy]|UL|u[lsy]?)?\b/
11560
- ],
11561
- operator:
11562
- /([<>~&^])\1\1|([*.:<>&])\2|<-|->|[!=:]=|<?\|{1,3}>?|\??(?:<=|>=|<>|[-+*/%=<>])\??|[!?^&]|~[+~-]|:>|:\?>?/
11563
- });
11564
- Prism.languages.insertBefore('fsharp', 'keyword', {
11565
- preprocessor: {
11566
- pattern: /(^[\t ]*)#.*/m,
11567
- lookbehind: true,
11568
- alias: 'property',
11569
- inside: {
11570
- directive: {
11571
- pattern: /(^#)\b(?:else|endif|if|light|line|nowarn)\b/,
11572
- lookbehind: true,
11573
- alias: 'keyword'
11574
- }
11575
- }
11576
- }
11577
- });
11578
- Prism.languages.insertBefore('fsharp', 'punctuation', {
11579
- 'computation-expression': {
11580
- pattern: /\b[_a-z]\w*(?=\s*\{)/i,
11581
- alias: 'keyword'
11582
- }
11583
- });
11584
- Prism.languages.insertBefore('fsharp', 'string', {
11585
- annotation: {
11586
- pattern: /\[<.+?>\]/,
11587
- greedy: true,
11588
- inside: {
11589
- punctuation: /^\[<|>\]$/,
11590
- 'class-name': {
11591
- pattern: /^\w+$|(^|;\s*)[A-Z]\w*(?=\()/,
11592
- lookbehind: true
11593
- },
11594
- 'annotation-content': {
11595
- pattern: /[\s\S]+/,
11596
- inside: Prism.languages.fsharp
11597
- }
11598
- }
11599
- },
11600
- char: {
11601
- pattern:
11602
- /'(?:[^\\']|\\(?:.|\d{3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}|U[a-fA-F\d]{8}))'B?/,
11603
- greedy: true
11604
- }
11605
- });
11604
+ function requireFortran () {
11605
+ if (hasRequiredFortran) return fortran_1;
11606
+ hasRequiredFortran = 1;
11607
+
11608
+ fortran_1 = fortran;
11609
+ fortran.displayName = 'fortran';
11610
+ fortran.aliases = [];
11611
+ function fortran(Prism) {
11612
+ Prism.languages.fortran = {
11613
+ 'quoted-number': {
11614
+ pattern: /[BOZ](['"])[A-F0-9]+\1/i,
11615
+ alias: 'number'
11616
+ },
11617
+ string: {
11618
+ pattern:
11619
+ /(?:\b\w+_)?(['"])(?:\1\1|&(?:\r\n?|\n)(?:[ \t]*!.*(?:\r\n?|\n)|(?![ \t]*!))|(?!\1).)*(?:\1|&)/,
11620
+ inside: {
11621
+ comment: {
11622
+ pattern: /(&(?:\r\n?|\n)\s*)!.*/,
11623
+ lookbehind: true
11624
+ }
11625
+ }
11626
+ },
11627
+ comment: {
11628
+ pattern: /!.*/,
11629
+ greedy: true
11630
+ },
11631
+ boolean: /\.(?:FALSE|TRUE)\.(?:_\w+)?/i,
11632
+ number: /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[ED][+-]?\d+)?(?:_\w+)?/i,
11633
+ keyword: [
11634
+ // Types
11635
+ /\b(?:CHARACTER|COMPLEX|DOUBLE ?PRECISION|INTEGER|LOGICAL|REAL)\b/i, // END statements
11636
+ /\b(?:END ?)?(?:BLOCK ?DATA|DO|FILE|FORALL|FUNCTION|IF|INTERFACE|MODULE(?! PROCEDURE)|PROGRAM|SELECT|SUBROUTINE|TYPE|WHERE)\b/i, // Statements
11637
+ /\b(?:ALLOCATABLE|ALLOCATE|BACKSPACE|CALL|CASE|CLOSE|COMMON|CONTAINS|CONTINUE|CYCLE|DATA|DEALLOCATE|DIMENSION|DO|END|EQUIVALENCE|EXIT|EXTERNAL|FORMAT|GO ?TO|IMPLICIT(?: NONE)?|INQUIRE|INTENT|INTRINSIC|MODULE PROCEDURE|NAMELIST|NULLIFY|OPEN|OPTIONAL|PARAMETER|POINTER|PRINT|PRIVATE|PUBLIC|READ|RETURN|REWIND|SAVE|SELECT|STOP|TARGET|WHILE|WRITE)\b/i, // Others
11638
+ /\b(?:ASSIGNMENT|DEFAULT|ELEMENTAL|ELSE|ELSEIF|ELSEWHERE|ENTRY|IN|INCLUDE|INOUT|KIND|NULL|ONLY|OPERATOR|OUT|PURE|RECURSIVE|RESULT|SEQUENCE|STAT|THEN|USE)\b/i
11639
+ ],
11640
+ operator: [
11641
+ /\*\*|\/\/|=>|[=\/]=|[<>]=?|::|[+\-*=%]|\.[A-Z]+\./i,
11642
+ {
11643
+ // Use lookbehind to prevent confusion with (/ /)
11644
+ pattern: /(^|(?!\().)\/(?!\))/,
11645
+ lookbehind: true
11646
+ }
11647
+ ],
11648
+ punctuation: /\(\/|\/\)|[(),;:&]/
11649
+ };
11650
+ }
11651
+ return fortran_1;
11652
+ }
11653
+
11654
+ var fsharp_1;
11655
+ var hasRequiredFsharp;
11656
+
11657
+ function requireFsharp () {
11658
+ if (hasRequiredFsharp) return fsharp_1;
11659
+ hasRequiredFsharp = 1;
11660
+
11661
+ fsharp_1 = fsharp;
11662
+ fsharp.displayName = 'fsharp';
11663
+ fsharp.aliases = [];
11664
+ function fsharp(Prism) {
11665
+ Prism.languages.fsharp = Prism.languages.extend('clike', {
11666
+ comment: [
11667
+ {
11668
+ pattern: /(^|[^\\])\(\*(?!\))[\s\S]*?\*\)/,
11669
+ lookbehind: true,
11670
+ greedy: true
11671
+ },
11672
+ {
11673
+ pattern: /(^|[^\\:])\/\/.*/,
11674
+ lookbehind: true,
11675
+ greedy: true
11676
+ }
11677
+ ],
11678
+ string: {
11679
+ pattern: /(?:"""[\s\S]*?"""|@"(?:""|[^"])*"|"(?:\\[\s\S]|[^\\"])*")B?/,
11680
+ greedy: true
11681
+ },
11682
+ 'class-name': {
11683
+ pattern:
11684
+ /(\b(?:exception|inherit|interface|new|of|type)\s+|\w\s*:\s*|\s:\??>\s*)[.\w]+\b(?:\s*(?:->|\*)\s*[.\w]+\b)*(?!\s*[:.])/,
11685
+ lookbehind: true,
11686
+ inside: {
11687
+ operator: /->|\*/,
11688
+ punctuation: /\./
11689
+ }
11690
+ },
11691
+ keyword:
11692
+ /\b(?:let|return|use|yield)(?:!\B|\b)|\b(?:abstract|and|as|asr|assert|atomic|base|begin|break|checked|class|component|const|constraint|constructor|continue|default|delegate|do|done|downcast|downto|eager|elif|else|end|event|exception|extern|external|false|finally|fixed|for|fun|function|functor|global|if|in|include|inherit|inline|interface|internal|land|lazy|lor|lsl|lsr|lxor|match|member|method|mixin|mod|module|mutable|namespace|new|not|null|object|of|open|or|override|parallel|private|process|protected|public|pure|rec|sealed|select|sig|static|struct|tailcall|then|to|trait|true|try|type|upcast|val|virtual|void|volatile|when|while|with)\b/,
11693
+ number: [
11694
+ /\b0x[\da-fA-F]+(?:LF|lf|un)?\b/,
11695
+ /\b0b[01]+(?:uy|y)?\b/,
11696
+ /(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[fm]|e[+-]?\d+)?\b/i,
11697
+ /\b\d+(?:[IlLsy]|UL|u[lsy]?)?\b/
11698
+ ],
11699
+ operator:
11700
+ /([<>~&^])\1\1|([*.:<>&])\2|<-|->|[!=:]=|<?\|{1,3}>?|\??(?:<=|>=|<>|[-+*/%=<>])\??|[!?^&]|~[+~-]|:>|:\?>?/
11701
+ });
11702
+ Prism.languages.insertBefore('fsharp', 'keyword', {
11703
+ preprocessor: {
11704
+ pattern: /(^[\t ]*)#.*/m,
11705
+ lookbehind: true,
11706
+ alias: 'property',
11707
+ inside: {
11708
+ directive: {
11709
+ pattern: /(^#)\b(?:else|endif|if|light|line|nowarn)\b/,
11710
+ lookbehind: true,
11711
+ alias: 'keyword'
11712
+ }
11713
+ }
11714
+ }
11715
+ });
11716
+ Prism.languages.insertBefore('fsharp', 'punctuation', {
11717
+ 'computation-expression': {
11718
+ pattern: /\b[_a-z]\w*(?=\s*\{)/i,
11719
+ alias: 'keyword'
11720
+ }
11721
+ });
11722
+ Prism.languages.insertBefore('fsharp', 'string', {
11723
+ annotation: {
11724
+ pattern: /\[<.+?>\]/,
11725
+ greedy: true,
11726
+ inside: {
11727
+ punctuation: /^\[<|>\]$/,
11728
+ 'class-name': {
11729
+ pattern: /^\w+$|(^|;\s*)[A-Z]\w*(?=\()/,
11730
+ lookbehind: true
11731
+ },
11732
+ 'annotation-content': {
11733
+ pattern: /[\s\S]+/,
11734
+ inside: Prism.languages.fsharp
11735
+ }
11736
+ }
11737
+ },
11738
+ char: {
11739
+ pattern:
11740
+ /'(?:[^\\']|\\(?:.|\d{3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}|U[a-fA-F\d]{8}))'B?/,
11741
+ greedy: true
11742
+ }
11743
+ });
11744
+ }
11745
+ return fsharp_1;
11606
11746
  }
11607
11747
 
11608
11748
  var ftl_1;
@@ -11807,98 +11947,125 @@ function requireGap () {
11807
11947
  return gap_1;
11808
11948
  }
11809
11949
 
11810
- var gcode_1 = gcode;
11811
- gcode.displayName = 'gcode';
11812
- gcode.aliases = [];
11813
- function gcode(Prism) {
11814
- Prism.languages.gcode = {
11815
- comment: /;.*|\B\(.*?\)\B/,
11816
- string: {
11817
- pattern: /"(?:""|[^"])*"/,
11818
- greedy: true
11819
- },
11820
- keyword: /\b[GM]\d+(?:\.\d+)?\b/,
11821
- property: /\b[A-Z]/,
11822
- checksum: {
11823
- pattern: /(\*)\d+/,
11824
- lookbehind: true,
11825
- alias: 'number'
11826
- },
11827
- // T0:0:0
11828
- punctuation: /[:*]/
11829
- };
11950
+ var gcode_1;
11951
+ var hasRequiredGcode;
11952
+
11953
+ function requireGcode () {
11954
+ if (hasRequiredGcode) return gcode_1;
11955
+ hasRequiredGcode = 1;
11956
+
11957
+ gcode_1 = gcode;
11958
+ gcode.displayName = 'gcode';
11959
+ gcode.aliases = [];
11960
+ function gcode(Prism) {
11961
+ Prism.languages.gcode = {
11962
+ comment: /;.*|\B\(.*?\)\B/,
11963
+ string: {
11964
+ pattern: /"(?:""|[^"])*"/,
11965
+ greedy: true
11966
+ },
11967
+ keyword: /\b[GM]\d+(?:\.\d+)?\b/,
11968
+ property: /\b[A-Z]/,
11969
+ checksum: {
11970
+ pattern: /(\*)\d+/,
11971
+ lookbehind: true,
11972
+ alias: 'number'
11973
+ },
11974
+ // T0:0:0
11975
+ punctuation: /[:*]/
11976
+ };
11977
+ }
11978
+ return gcode_1;
11830
11979
  }
11831
11980
 
11832
- var gdscript_1 = gdscript;
11833
- gdscript.displayName = 'gdscript';
11834
- gdscript.aliases = [];
11835
- function gdscript(Prism) {
11836
- Prism.languages.gdscript = {
11837
- comment: /#.*/,
11838
- string: {
11839
- pattern:
11840
- /@?(?:("|')(?:(?!\1)[^\n\\]|\\[\s\S])*\1(?!"|')|"""(?:[^\\]|\\[\s\S])*?""")/,
11841
- greedy: true
11842
- },
11843
- 'class-name': {
11844
- // class_name Foo, extends Bar, class InnerClass
11845
- // export(int) var baz, export(int, 0) var i
11846
- // as Node
11847
- // const FOO: int = 9, var bar: bool = true
11848
- // func add(reference: Item, amount: int) -> Item:
11849
- pattern:
11850
- /(^(?:class|class_name|extends)[ \t]+|^export\([ \t]*|\bas[ \t]+|(?:\b(?:const|var)[ \t]|[,(])[ \t]*\w+[ \t]*:[ \t]*|->[ \t]*)[a-zA-Z_]\w*/m,
11851
- lookbehind: true
11852
- },
11853
- keyword:
11854
- /\b(?:and|as|assert|break|breakpoint|class|class_name|const|continue|elif|else|enum|export|extends|for|func|if|in|is|master|mastersync|match|not|null|onready|or|pass|preload|puppet|puppetsync|remote|remotesync|return|self|setget|signal|static|tool|var|while|yield)\b/,
11855
- function: /\b[a-z_]\w*(?=[ \t]*\()/i,
11856
- variable: /\$\w+/,
11857
- number: [
11858
- /\b0b[01_]+\b|\b0x[\da-fA-F_]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.[\d_]+)(?:e[+-]?[\d_]+)?\b/,
11859
- /\b(?:INF|NAN|PI|TAU)\b/
11860
- ],
11861
- constant: /\b[A-Z][A-Z_\d]*\b/,
11862
- boolean: /\b(?:false|true)\b/,
11863
- operator: /->|:=|&&|\|\||<<|>>|[-+*/%&|!<>=]=?|[~^]/,
11864
- punctuation: /[.:,;()[\]{}]/
11865
- };
11981
+ var gdscript_1;
11982
+ var hasRequiredGdscript;
11983
+
11984
+ function requireGdscript () {
11985
+ if (hasRequiredGdscript) return gdscript_1;
11986
+ hasRequiredGdscript = 1;
11987
+
11988
+ gdscript_1 = gdscript;
11989
+ gdscript.displayName = 'gdscript';
11990
+ gdscript.aliases = [];
11991
+ function gdscript(Prism) {
11992
+ Prism.languages.gdscript = {
11993
+ comment: /#.*/,
11994
+ string: {
11995
+ pattern:
11996
+ /@?(?:("|')(?:(?!\1)[^\n\\]|\\[\s\S])*\1(?!"|')|"""(?:[^\\]|\\[\s\S])*?""")/,
11997
+ greedy: true
11998
+ },
11999
+ 'class-name': {
12000
+ // class_name Foo, extends Bar, class InnerClass
12001
+ // export(int) var baz, export(int, 0) var i
12002
+ // as Node
12003
+ // const FOO: int = 9, var bar: bool = true
12004
+ // func add(reference: Item, amount: int) -> Item:
12005
+ pattern:
12006
+ /(^(?:class|class_name|extends)[ \t]+|^export\([ \t]*|\bas[ \t]+|(?:\b(?:const|var)[ \t]|[,(])[ \t]*\w+[ \t]*:[ \t]*|->[ \t]*)[a-zA-Z_]\w*/m,
12007
+ lookbehind: true
12008
+ },
12009
+ keyword:
12010
+ /\b(?:and|as|assert|break|breakpoint|class|class_name|const|continue|elif|else|enum|export|extends|for|func|if|in|is|master|mastersync|match|not|null|onready|or|pass|preload|puppet|puppetsync|remote|remotesync|return|self|setget|signal|static|tool|var|while|yield)\b/,
12011
+ function: /\b[a-z_]\w*(?=[ \t]*\()/i,
12012
+ variable: /\$\w+/,
12013
+ number: [
12014
+ /\b0b[01_]+\b|\b0x[\da-fA-F_]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.[\d_]+)(?:e[+-]?[\d_]+)?\b/,
12015
+ /\b(?:INF|NAN|PI|TAU)\b/
12016
+ ],
12017
+ constant: /\b[A-Z][A-Z_\d]*\b/,
12018
+ boolean: /\b(?:false|true)\b/,
12019
+ operator: /->|:=|&&|\|\||<<|>>|[-+*/%&|!<>=]=?|[~^]/,
12020
+ punctuation: /[.:,;()[\]{}]/
12021
+ };
12022
+ }
12023
+ return gdscript_1;
11866
12024
  }
11867
12025
 
11868
- var gedcom_1 = gedcom;
11869
- gedcom.displayName = 'gedcom';
11870
- gedcom.aliases = [];
11871
- function gedcom(Prism) {
11872
- Prism.languages.gedcom = {
11873
- 'line-value': {
11874
- // Preceded by level, optional pointer, and tag
11875
- pattern:
11876
- /(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?\w+ ).+/m,
11877
- lookbehind: true,
11878
- inside: {
11879
- pointer: {
11880
- pattern: /^@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@$/,
11881
- alias: 'variable'
11882
- }
11883
- }
11884
- },
11885
- tag: {
11886
- // Preceded by level and optional pointer
11887
- pattern:
11888
- /(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?)\w+/m,
11889
- lookbehind: true,
11890
- alias: 'string'
11891
- },
11892
- level: {
11893
- pattern: /(^[\t ]*)\d+/m,
11894
- lookbehind: true,
11895
- alias: 'number'
11896
- },
11897
- pointer: {
11898
- pattern: /@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@/,
11899
- alias: 'variable'
11900
- }
11901
- };
12026
+ var gedcom_1;
12027
+ var hasRequiredGedcom;
12028
+
12029
+ function requireGedcom () {
12030
+ if (hasRequiredGedcom) return gedcom_1;
12031
+ hasRequiredGedcom = 1;
12032
+
12033
+ gedcom_1 = gedcom;
12034
+ gedcom.displayName = 'gedcom';
12035
+ gedcom.aliases = [];
12036
+ function gedcom(Prism) {
12037
+ Prism.languages.gedcom = {
12038
+ 'line-value': {
12039
+ // Preceded by level, optional pointer, and tag
12040
+ pattern:
12041
+ /(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?\w+ ).+/m,
12042
+ lookbehind: true,
12043
+ inside: {
12044
+ pointer: {
12045
+ pattern: /^@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@$/,
12046
+ alias: 'variable'
12047
+ }
12048
+ }
12049
+ },
12050
+ tag: {
12051
+ // Preceded by level and optional pointer
12052
+ pattern:
12053
+ /(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?)\w+/m,
12054
+ lookbehind: true,
12055
+ alias: 'string'
12056
+ },
12057
+ level: {
12058
+ pattern: /(^[\t ]*)\d+/m,
12059
+ lookbehind: true,
12060
+ alias: 'number'
12061
+ },
12062
+ pointer: {
12063
+ pattern: /@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@/,
12064
+ alias: 'variable'
12065
+ }
12066
+ };
12067
+ }
12068
+ return gedcom_1;
11902
12069
  }
11903
12070
 
11904
12071
  var gherkin_1;
@@ -12127,89 +12294,107 @@ function requireGml () {
12127
12294
  return gml_1;
12128
12295
  }
12129
12296
 
12130
- var gn_1 = gn;
12131
- gn.displayName = 'gn';
12132
- gn.aliases = ['gni'];
12133
- function gn(Prism) {
12134
- // https://gn.googlesource.com/gn/+/refs/heads/main/docs/reference.md#grammar
12135
- Prism.languages.gn = {
12136
- comment: {
12137
- pattern: /#.*/,
12138
- greedy: true
12139
- },
12140
- 'string-literal': {
12141
- pattern: /(^|[^\\"])"(?:[^\r\n"\\]|\\.)*"/,
12142
- lookbehind: true,
12143
- greedy: true,
12144
- inside: {
12145
- interpolation: {
12146
- pattern:
12147
- /((?:^|[^\\])(?:\\{2})*)\$(?:\{[\s\S]*?\}|[a-zA-Z_]\w*|0x[a-fA-F0-9]{2})/,
12148
- lookbehind: true,
12149
- inside: {
12150
- number: /^\$0x[\s\S]{2}$/,
12151
- variable: /^\$\w+$/,
12152
- 'interpolation-punctuation': {
12153
- pattern: /^\$\{|\}$/,
12154
- alias: 'punctuation'
12155
- },
12156
- expression: {
12157
- pattern: /[\s\S]+/,
12158
- inside: null // see below
12159
- }
12160
- }
12161
- },
12162
- string: /[\s\S]+/
12163
- }
12164
- },
12165
- keyword: /\b(?:else|if)\b/,
12166
- boolean: /\b(?:false|true)\b/,
12167
- 'builtin-function': {
12168
- // a few functions get special highlighting to improve readability
12169
- pattern:
12170
- /\b(?:assert|defined|foreach|import|pool|print|template|tool|toolchain)(?=\s*\()/i,
12171
- alias: 'keyword'
12172
- },
12173
- function: /\b[a-z_]\w*(?=\s*\()/i,
12174
- constant:
12175
- /\b(?:current_cpu|current_os|current_toolchain|default_toolchain|host_cpu|host_os|root_build_dir|root_gen_dir|root_out_dir|target_cpu|target_gen_dir|target_os|target_out_dir)\b/,
12176
- number: /-?\b\d+\b/,
12177
- operator: /[-+!=<>]=?|&&|\|\|/,
12178
- punctuation: /[(){}[\],.]/
12179
- };
12180
- Prism.languages.gn['string-literal'].inside['interpolation'].inside[
12181
- 'expression'
12182
- ].inside = Prism.languages.gn;
12183
- Prism.languages.gni = Prism.languages.gn;
12297
+ var gn_1;
12298
+ var hasRequiredGn;
12299
+
12300
+ function requireGn () {
12301
+ if (hasRequiredGn) return gn_1;
12302
+ hasRequiredGn = 1;
12303
+
12304
+ gn_1 = gn;
12305
+ gn.displayName = 'gn';
12306
+ gn.aliases = ['gni'];
12307
+ function gn(Prism) {
12308
+ // https://gn.googlesource.com/gn/+/refs/heads/main/docs/reference.md#grammar
12309
+ Prism.languages.gn = {
12310
+ comment: {
12311
+ pattern: /#.*/,
12312
+ greedy: true
12313
+ },
12314
+ 'string-literal': {
12315
+ pattern: /(^|[^\\"])"(?:[^\r\n"\\]|\\.)*"/,
12316
+ lookbehind: true,
12317
+ greedy: true,
12318
+ inside: {
12319
+ interpolation: {
12320
+ pattern:
12321
+ /((?:^|[^\\])(?:\\{2})*)\$(?:\{[\s\S]*?\}|[a-zA-Z_]\w*|0x[a-fA-F0-9]{2})/,
12322
+ lookbehind: true,
12323
+ inside: {
12324
+ number: /^\$0x[\s\S]{2}$/,
12325
+ variable: /^\$\w+$/,
12326
+ 'interpolation-punctuation': {
12327
+ pattern: /^\$\{|\}$/,
12328
+ alias: 'punctuation'
12329
+ },
12330
+ expression: {
12331
+ pattern: /[\s\S]+/,
12332
+ inside: null // see below
12333
+ }
12334
+ }
12335
+ },
12336
+ string: /[\s\S]+/
12337
+ }
12338
+ },
12339
+ keyword: /\b(?:else|if)\b/,
12340
+ boolean: /\b(?:false|true)\b/,
12341
+ 'builtin-function': {
12342
+ // a few functions get special highlighting to improve readability
12343
+ pattern:
12344
+ /\b(?:assert|defined|foreach|import|pool|print|template|tool|toolchain)(?=\s*\()/i,
12345
+ alias: 'keyword'
12346
+ },
12347
+ function: /\b[a-z_]\w*(?=\s*\()/i,
12348
+ constant:
12349
+ /\b(?:current_cpu|current_os|current_toolchain|default_toolchain|host_cpu|host_os|root_build_dir|root_gen_dir|root_out_dir|target_cpu|target_gen_dir|target_os|target_out_dir)\b/,
12350
+ number: /-?\b\d+\b/,
12351
+ operator: /[-+!=<>]=?|&&|\|\|/,
12352
+ punctuation: /[(){}[\],.]/
12353
+ };
12354
+ Prism.languages.gn['string-literal'].inside['interpolation'].inside[
12355
+ 'expression'
12356
+ ].inside = Prism.languages.gn;
12357
+ Prism.languages.gni = Prism.languages.gn;
12358
+ }
12359
+ return gn_1;
12184
12360
  }
12185
12361
 
12186
- var goModule_1 = goModule;
12187
- goModule.displayName = 'goModule';
12188
- goModule.aliases = [];
12189
- function goModule(Prism) {
12190
- // https://go.dev/ref/mod#go-mod-file-module
12191
- Prism.languages['go-mod'] = Prism.languages['go-module'] = {
12192
- comment: {
12193
- pattern: /\/\/.*/,
12194
- greedy: true
12195
- },
12196
- version: {
12197
- pattern: /(^|[\s()[\],])v\d+\.\d+\.\d+(?:[+-][-+.\w]*)?(?![^\s()[\],])/,
12198
- lookbehind: true,
12199
- alias: 'number'
12200
- },
12201
- 'go-version': {
12202
- pattern: /((?:^|\s)go\s+)\d+(?:\.\d+){1,2}/,
12203
- lookbehind: true,
12204
- alias: 'number'
12205
- },
12206
- keyword: {
12207
- pattern: /^([ \t]*)(?:exclude|go|module|replace|require|retract)\b/m,
12208
- lookbehind: true
12209
- },
12210
- operator: /=>/,
12211
- punctuation: /[()[\],]/
12212
- };
12362
+ var goModule_1;
12363
+ var hasRequiredGoModule;
12364
+
12365
+ function requireGoModule () {
12366
+ if (hasRequiredGoModule) return goModule_1;
12367
+ hasRequiredGoModule = 1;
12368
+
12369
+ goModule_1 = goModule;
12370
+ goModule.displayName = 'goModule';
12371
+ goModule.aliases = [];
12372
+ function goModule(Prism) {
12373
+ // https://go.dev/ref/mod#go-mod-file-module
12374
+ Prism.languages['go-mod'] = Prism.languages['go-module'] = {
12375
+ comment: {
12376
+ pattern: /\/\/.*/,
12377
+ greedy: true
12378
+ },
12379
+ version: {
12380
+ pattern: /(^|[\s()[\],])v\d+\.\d+\.\d+(?:[+-][-+.\w]*)?(?![^\s()[\],])/,
12381
+ lookbehind: true,
12382
+ alias: 'number'
12383
+ },
12384
+ 'go-version': {
12385
+ pattern: /((?:^|\s)go\s+)\d+(?:\.\d+){1,2}/,
12386
+ lookbehind: true,
12387
+ alias: 'number'
12388
+ },
12389
+ keyword: {
12390
+ pattern: /^([ \t]*)(?:exclude|go|module|replace|require|retract)\b/m,
12391
+ lookbehind: true
12392
+ },
12393
+ operator: /=>/,
12394
+ punctuation: /[()[\],]/
12395
+ };
12396
+ }
12397
+ return goModule_1;
12213
12398
  }
12214
12399
 
12215
12400
  var go_1;
@@ -27780,44 +27965,44 @@ refractor.register(cshtml_1);
27780
27965
  refractor.register(csp_1);
27781
27966
  refractor.register(cssExtras_1);
27782
27967
  refractor.register(csv_1);
27783
- refractor.register(cypher_1);
27968
+ refractor.register(requireCypher());
27784
27969
  refractor.register(d_1);
27785
- refractor.register(dart_1);
27970
+ refractor.register(requireDart());
27786
27971
  refractor.register(dataweave_1);
27787
27972
  refractor.register(dax_1);
27788
- refractor.register(requireDhall());
27973
+ refractor.register(dhall_1);
27789
27974
  refractor.register(diff_1);
27790
- refractor.register(django_1);
27975
+ refractor.register(requireDjango());
27791
27976
  refractor.register(dnsZoneFile_1);
27792
27977
  refractor.register(docker_1);
27793
- refractor.register(requireDot());
27978
+ refractor.register(dot_1);
27794
27979
  refractor.register(requireEbnf());
27795
27980
  refractor.register(editorconfig_1);
27796
- refractor.register(eiffel_1);
27797
- refractor.register(ejs_1);
27798
- refractor.register(elixir_1);
27799
- refractor.register(elm_1);
27800
- refractor.register(erb_1);
27801
- refractor.register(erlang_1);
27802
- refractor.register(etlua_1);
27803
- refractor.register(excelFormula_1);
27804
- refractor.register(factor_1);
27805
- refractor.register(_false);
27806
- refractor.register(firestoreSecurityRules_1);
27807
- refractor.register(flow_1);
27808
- refractor.register(fortran_1);
27809
- refractor.register(fsharp_1);
27981
+ refractor.register(requireEiffel());
27982
+ refractor.register(requireEjs());
27983
+ refractor.register(requireElixir());
27984
+ refractor.register(requireElm());
27985
+ refractor.register(requireErb());
27986
+ refractor.register(requireErlang());
27987
+ refractor.register(requireEtlua());
27988
+ refractor.register(requireExcelFormula());
27989
+ refractor.register(requireFactor());
27990
+ refractor.register(require_false());
27991
+ refractor.register(requireFirestoreSecurityRules());
27992
+ refractor.register(requireFlow());
27993
+ refractor.register(requireFortran());
27994
+ refractor.register(requireFsharp());
27810
27995
  refractor.register(requireFtl());
27811
27996
  refractor.register(requireGap());
27812
- refractor.register(gcode_1);
27813
- refractor.register(gdscript_1);
27814
- refractor.register(gedcom_1);
27997
+ refractor.register(requireGcode());
27998
+ refractor.register(requireGdscript());
27999
+ refractor.register(requireGedcom());
27815
28000
  refractor.register(requireGherkin());
27816
28001
  refractor.register(requireGit());
27817
28002
  refractor.register(requireGlsl());
27818
28003
  refractor.register(requireGml());
27819
- refractor.register(gn_1);
27820
- refractor.register(goModule_1);
28004
+ refractor.register(requireGn());
28005
+ refractor.register(requireGoModule());
27821
28006
  refractor.register(requireGo());
27822
28007
  refractor.register(requireGraphql());
27823
28008
  refractor.register(requireGroovy());
@@ -27872,7 +28057,7 @@ refractor.register(requireLivescript());
27872
28057
  refractor.register(requireLlvm());
27873
28058
  refractor.register(requireLog());
27874
28059
  refractor.register(requireLolcode());
27875
- refractor.register(lua_1);
28060
+ refractor.register(requireLua());
27876
28061
  refractor.register(requireMagma());
27877
28062
  refractor.register(requireMakefile());
27878
28063
  refractor.register(requireMarkdown());