| @@ -3,9 +3,9 @@ | ||
| 3 | 3 | "This file has been converted from https://github.com/MagicStack/MagicPython/blob/master/grammars/MagicPython.tmLanguage", |
| 4 | 4 | "If you want to provide a fix or improvement, please create a pull request against the original repository.", |
| 5 | 5 | "Once accepted there, we are happy to receive an update request." |
| 6 | 6 | ], |
| 7 | - "version": "https://github.com/MagicStack/MagicPython/commit/7d0f2b22a5ad8fccbd7341bc7b7a715169283044", | |
| 7 | + "version": "https://github.com/MagicStack/MagicPython/commit/b2b4f4ae7b4e6284e80bda8080106b93bd588f9e", | |
| 8 | 8 | "name": "python", |
| 9 | 9 | "scopeName": "source.python", |
| 10 | 10 | "patterns": [ |
| 11 | 11 | { |
| @@ -269,16 +269,8 @@ | ||
| 269 | 269 | }, |
| 270 | 270 | { |
| 271 | 271 | "name": "storage.type.class.python", |
| 272 | 272 | "match": "\\b(?<!\\.)(class)\\b" |
| 273 | - }, | |
| 274 | - { | |
| 275 | - "match": "(?x)\n ^\\s*(\n case | match\n )(?=\\s*([-+\\w\\d(\\[{'\":#]|$))\\b\n", | |
| 276 | - "captures": { | |
| 277 | - "1": { | |
| 278 | - "name": "keyword.control.flow.python" | |
| 279 | - } | |
| 280 | - } | |
| 281 | 273 | } |
| 282 | 274 | ] |
| 283 | 275 | }, |
| 284 | 276 | "expression-bare": { |
| @@ -554,9 +546,9 @@ | ||
| 554 | 546 | "name": "keyword.operator.assignment.python", |
| 555 | 547 | "match": "(?x)\n <<= | >>= | //= | \\*\\*=\n | \\+= | -= | /= | @=\n | \\*= | %= | ~= | \\^= | &= | \\|=\n | =(?!=)\n" |
| 556 | 548 | }, |
| 557 | 549 | "operator": { |
| 558 | - "match": "(?x)\n \\b(?<!\\.)\n (?:\n (and | or | not | in | is) (?# 1)\n |\n (for | if | else | await | (?:yield(?:\\s+from)?)) (?# 2)\n )\n (?!\\s*:)\\b\n\n | (<< | >> | & | \\| | \\^ | ~) (?# 3)\n\n | (\\*\\* | \\* | \\+ | - | % | // | / | @) (?# 4)\n\n | (!= | == | >= | <= | < | >) (?# 5)\n\n | (:=) (?# 6)\n", | |
| 550 | + "match": "(?x)\n \\b(?<!\\.)\n (?:\n (and | or | not | in | is) (?# 1)\n |\n (for | if | else | await | (?:yield(?:\\s+from)?)) (?# 2)\n )\n (?!\\s*:)\\b\n\n | (<< | >> | & | \\| | \\^ | ~) (?# 3)\n\n | (\\*\\* | \\* | \\+ | - | % | // | / | @) (?# 4)\n\n | (!= | == | >= | <= | < | >) (?# 5)\n", | |
| 559 | 551 | "captures": { |
| 560 | 552 | "1": { |
| 561 | 553 | "name": "keyword.operator.logical.python" |
| 562 | 554 | }, |
| @@ -570,11 +562,8 @@ | ||
| 570 | 562 | "name": "keyword.operator.arithmetic.python" |
| 571 | 563 | }, |
| 572 | 564 | "5": { |
| 573 | 565 | "name": "keyword.operator.comparison.python" |
| 574 | - }, | |
| 575 | - "6": { | |
| 576 | - "name": "keyword.operator.assignment.python" | |
| 577 | 566 | } |
| 578 | 567 | } |
| 579 | 568 | }, |
| 580 | 569 | "punctuation": { |
| @@ -697,8 +686,20 @@ | ||
| 697 | 686 | "include": "#regexp-single-one-line" |
| 698 | 687 | }, |
| 699 | 688 | { |
| 700 | 689 | "include": "#regexp-double-one-line" |
| 690 | + }, | |
| 691 | + { | |
| 692 | + "include": "#fregexp-single-three-line" | |
| 693 | + }, | |
| 694 | + { | |
| 695 | + "include": "#fregexp-double-three-line" | |
| 696 | + }, | |
| 697 | + { | |
| 698 | + "include": "#fregexp-single-one-line" | |
| 699 | + }, | |
| 700 | + { | |
| 701 | + "include": "#fregexp-double-one-line" | |
| 701 | 702 | } |
| 702 | 703 | ] |
| 703 | 704 | }, |
| 704 | 705 | "string": { |
| @@ -1150,12 +1151,8 @@ | ||
| 1150 | 1151 | }, |
| 1151 | 1152 | "contentName": "meta.function.lambda.parameters.python", |
| 1152 | 1153 | "patterns": [ |
| 1153 | 1154 | { |
| 1154 | - "name": "keyword.operator.positional.parameter.python", | |
| 1155 | - "match": "/" | |
| 1156 | - }, | |
| 1157 | - { | |
| 1158 | 1155 | "name": "keyword.operator.unpacking.parameter.python", |
| 1159 | 1156 | "match": "(\\*\\*|\\*)" |
| 1160 | 1157 | }, |
| 1161 | 1158 | { |
| @@ -1308,12 +1305,8 @@ | ||
| 1308 | 1305 | } |
| 1309 | 1306 | }, |
| 1310 | 1307 | "patterns": [ |
| 1311 | 1308 | { |
| 1312 | - "name": "keyword.operator.positional.parameter.python", | |
| 1313 | - "match": "/" | |
| 1314 | - }, | |
| 1315 | - { | |
| 1316 | 1309 | "name": "keyword.operator.unpacking.parameter.python", |
| 1317 | 1310 | "match": "(\\*\\*|\\*)" |
| 1318 | 1311 | }, |
| 1319 | 1312 | { |
| @@ -1708,9 +1701,9 @@ | ||
| 1708 | 1701 | "builtin-functions": { |
| 1709 | 1702 | "patterns": [ |
| 1710 | 1703 | { |
| 1711 | 1704 | "name": "support.function.builtin.python", |
| 1712 | - "match": "(?x)\n (?<!\\.) \\b(\n __import__ | abs | aiter | all | any | anext | ascii | bin\n | breakpoint | callable | chr | compile | copyright | credits\n | delattr | dir | divmod | enumerate | eval | exec | exit\n | filter | format | getattr | globals | hasattr | hash | help\n | hex | id | input | isinstance | issubclass | iter | len\n | license | locals | map | max | memoryview | min | next\n | oct | open | ord | pow | print | quit | range | reload | repr\n | reversed | round | setattr | sorted | sum | vars | zip\n )\\b\n" | |
| 1705 | + "match": "(?x)\n (?<!\\.) \\b(\n __import__ | abs | all | any | ascii | bin | breakpoint | callable\n | chr | compile | copyright | credits | delattr | dir | divmod\n | enumerate | eval | exec | exit | filter | format | getattr\n | globals | hasattr | hash | help | hex | id | input\n | isinstance | issubclass | iter | len | license | locals | map\n | max | memoryview | min | next | oct | open | ord | pow | print\n | quit | range | reload | repr | reversed | round\n | setattr | sorted | sum | vars | zip\n )\\b\n" | |
| 1713 | 1706 | }, |
| 1714 | 1707 | { |
| 1715 | 1708 | "name": "variable.legacy.builtin.python", |
| 1716 | 1709 | "match": "(?x)\n (?<!\\.) \\b(\n file | reduce | intern | raw_input | unicode | cmp | basestring\n | execfile | long | xrange\n )\\b\n" |
| @@ -1722,9 +1715,9 @@ | ||
| 1722 | 1715 | "match": "(?x)\n (?<!\\.) \\b(\n bool | bytearray | bytes | classmethod | complex | dict\n | float | frozenset | int | list | object | property\n | set | slice | staticmethod | str | tuple | type\n\n (?# Although 'super' is not a type, it's related to types,\n and is special enough to be highlighted differently from\n other built-ins)\n | super\n )\\b\n" |
| 1723 | 1716 | }, |
| 1724 | 1717 | "magic-function-names": { |
| 1725 | 1718 | "comment": "these methods have magic interpretation by python and are generally called\nindirectly through syntactic constructs\n", |
| 1726 | - "match": "(?x)\n \\b(\n __(?:\n abs | add | aenter | aexit | aiter | and | anext\n | await | bool | call | ceil | class_getitem\n | cmp | coerce | complex | contains | copy\n | deepcopy | del | delattr | delete | delitem\n | delslice | dir | div | divmod | enter | eq\n | exit | float | floor | floordiv | format | ge\n | get | getattr | getattribute | getinitargs\n | getitem | getnewargs | getslice | getstate | gt\n | hash | hex | iadd | iand | idiv | ifloordiv |\n | ilshift | imod | imul | index | init\n | instancecheck | int | invert | ior | ipow\n | irshift | isub | iter | itruediv | ixor | le\n | len | long | lshift | lt | missing | mod | mul\n | ne | neg | new | next | nonzero | oct | or | pos\n | pow | radd | rand | rdiv | rdivmod | reduce\n | reduce_ex | repr | reversed | rfloordiv |\n | rlshift | rmod | rmul | ror | round | rpow\n | rrshift | rshift | rsub | rtruediv | rxor | set\n | setattr | setitem | set_name | setslice\n | setstate | sizeof | str | sub | subclasscheck\n | truediv | trunc | unicode | xor | matmul\n | rmatmul | imatmul | init_subclass | set_name\n | fspath | bytes | prepare | length_hint\n )__\n )\\b\n", | |
| 1719 | + "match": "(?x)\n \\b(\n __(?:\n abs | add | aenter | aexit | aiter | and | anext | await\n | bool | call | ceil | cmp | coerce | complex | contains\n | copy | deepcopy | del | delattr | delete | delitem\n | delslice | dir | div | divmod | enter | eq | exit | float\n | floor | floordiv | format | ge | get | getattr\n | getattribute | getinitargs | getitem | getnewargs\n | getslice | getstate | gt | hash | hex | iadd | iand | idiv\n | ifloordiv | ilshift | imod | imul | index | init\n | instancecheck | int | invert | ior | ipow | irshift | isub\n | iter | itruediv | ixor | le | len | long | lshift | lt\n | missing | mod | mul | ne | neg | new | next | nonzero | oct | or\n | pos | pow | radd | rand | rdiv | rdivmod | reduce\n | reduce_ex | repr | reversed | rfloordiv | rlshift | rmod\n | rmul | ror | round | rpow | rrshift | rshift | rsub\n | rtruediv | rxor | set | setattr | setitem | setslice\n | setstate | sizeof | str | sub | subclasscheck | truediv\n | trunc | unicode | xor | matmul | rmatmul | imatmul\n | init_subclass | set_name | fspath | bytes | prepare\n )__\n )\\b\n", | |
| 1727 | 1720 | "captures": { |
| 1728 | 1721 | "1": { |
| 1729 | 1722 | "name": "support.function.magic.python" |
| 1730 | 1723 | } |
| @@ -1731,9 +1724,9 @@ | ||
| 1731 | 1724 | } |
| 1732 | 1725 | }, |
| 1733 | 1726 | "magic-variable-names": { |
| 1734 | 1727 | "comment": "magic variables which a class/module may have.", |
| 1735 | - "match": "(?x)\n \\b(\n __(?:\n all | annotations | bases | builtins | class\n | closure | code | debug | defaults | dict | doc | file | func\n | globals | kwdefaults | match_args | members | metaclass | methods\n | module | mro | mro_entries | name | qualname | post_init | self\n | signature | slots | subclasses | version | weakref | wrapped\n | classcell | spec | path | package | future | traceback\n )__\n )\\b\n", | |
| 1728 | + "match": "(?x)\n \\b(\n __(?:\n all | bases | builtins | class | class_getitem | code | debug\n | defaults | dict | doc | file | func | kwdefaults | members\n | metaclass | methods | module | mro | mro_entries | name\n | qualname | post_init | self | signature | slots | subclasses\n | version | weakref | wrapped | annotations | classcell\n | spec | path | package | future | traceback\n )__\n )\\b\n", | |
| 1736 | 1729 | "captures": { |
| 1737 | 1730 | "1": { |
| 1738 | 1731 | "name": "support.variable.magic.python" |
| 1739 | 1732 | } |
| @@ -3420,8 +3413,1142 @@ | ||
| 3420 | 3413 | "include": "#double-three-regexp-expression" |
| 3421 | 3414 | } |
| 3422 | 3415 | ] |
| 3423 | 3416 | }, |
| 3417 | + "single-one-fregexp-expression": { | |
| 3418 | + "patterns": [ | |
| 3419 | + { | |
| 3420 | + "include": "#fregexp-base-expression" | |
| 3421 | + }, | |
| 3422 | + { | |
| 3423 | + "include": "#single-one-regexp-character-set" | |
| 3424 | + }, | |
| 3425 | + { | |
| 3426 | + "include": "#single-one-regexp-comments" | |
| 3427 | + }, | |
| 3428 | + { | |
| 3429 | + "include": "#regexp-flags" | |
| 3430 | + }, | |
| 3431 | + { | |
| 3432 | + "include": "#single-one-regexp-named-group" | |
| 3433 | + }, | |
| 3434 | + { | |
| 3435 | + "include": "#regexp-backreference" | |
| 3436 | + }, | |
| 3437 | + { | |
| 3438 | + "include": "#single-one-fregexp-lookahead" | |
| 3439 | + }, | |
| 3440 | + { | |
| 3441 | + "include": "#single-one-fregexp-lookahead-negative" | |
| 3442 | + }, | |
| 3443 | + { | |
| 3444 | + "include": "#single-one-fregexp-lookbehind" | |
| 3445 | + }, | |
| 3446 | + { | |
| 3447 | + "include": "#single-one-fregexp-lookbehind-negative" | |
| 3448 | + }, | |
| 3449 | + { | |
| 3450 | + "include": "#single-one-fregexp-conditional" | |
| 3451 | + }, | |
| 3452 | + { | |
| 3453 | + "include": "#single-one-fregexp-parentheses-non-capturing" | |
| 3454 | + }, | |
| 3455 | + { | |
| 3456 | + "include": "#single-one-fregexp-parentheses" | |
| 3457 | + } | |
| 3458 | + ] | |
| 3459 | + }, | |
| 3460 | + "single-one-fregexp-named-group": { | |
| 3461 | + "name": "meta.named.regexp", | |
| 3462 | + "begin": "(?x)\n (\\() (\\?P <\\w+(?:\\s+[[:alnum:]]+)?>)\n", | |
| 3463 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3464 | + "beginCaptures": { | |
| 3465 | + "1": { | |
| 3466 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.begin.regexp" | |
| 3467 | + }, | |
| 3468 | + "2": { | |
| 3469 | + "name": "entity.name.tag.named.group.regexp" | |
| 3470 | + } | |
| 3471 | + }, | |
| 3472 | + "endCaptures": { | |
| 3473 | + "1": { | |
| 3474 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.end.regexp" | |
| 3475 | + }, | |
| 3476 | + "2": { | |
| 3477 | + "name": "invalid.illegal.newline.python" | |
| 3478 | + } | |
| 3479 | + }, | |
| 3480 | + "patterns": [ | |
| 3481 | + { | |
| 3482 | + "include": "#single-one-fregexp-expression" | |
| 3483 | + } | |
| 3484 | + ] | |
| 3485 | + }, | |
| 3486 | + "single-one-fregexp-lookahead": { | |
| 3487 | + "begin": "(\\()\\?=", | |
| 3488 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3489 | + "beginCaptures": { | |
| 3490 | + "0": { | |
| 3491 | + "name": "keyword.operator.lookahead.regexp" | |
| 3492 | + }, | |
| 3493 | + "1": { | |
| 3494 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 3495 | + } | |
| 3496 | + }, | |
| 3497 | + "endCaptures": { | |
| 3498 | + "1": { | |
| 3499 | + "name": "keyword.operator.lookahead.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 3500 | + }, | |
| 3501 | + "2": { | |
| 3502 | + "name": "invalid.illegal.newline.python" | |
| 3503 | + } | |
| 3504 | + }, | |
| 3505 | + "patterns": [ | |
| 3506 | + { | |
| 3507 | + "include": "#single-one-fregexp-expression" | |
| 3508 | + } | |
| 3509 | + ] | |
| 3510 | + }, | |
| 3511 | + "single-one-fregexp-lookahead-negative": { | |
| 3512 | + "begin": "(\\()\\?!", | |
| 3513 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3514 | + "beginCaptures": { | |
| 3515 | + "0": { | |
| 3516 | + "name": "keyword.operator.lookahead.negative.regexp" | |
| 3517 | + }, | |
| 3518 | + "1": { | |
| 3519 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 3520 | + } | |
| 3521 | + }, | |
| 3522 | + "endCaptures": { | |
| 3523 | + "1": { | |
| 3524 | + "name": "keyword.operator.lookahead.negative.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 3525 | + }, | |
| 3526 | + "2": { | |
| 3527 | + "name": "invalid.illegal.newline.python" | |
| 3528 | + } | |
| 3529 | + }, | |
| 3530 | + "patterns": [ | |
| 3531 | + { | |
| 3532 | + "include": "#single-one-fregexp-expression" | |
| 3533 | + } | |
| 3534 | + ] | |
| 3535 | + }, | |
| 3536 | + "single-one-fregexp-lookbehind": { | |
| 3537 | + "begin": "(\\()\\?<=", | |
| 3538 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3539 | + "beginCaptures": { | |
| 3540 | + "0": { | |
| 3541 | + "name": "keyword.operator.lookbehind.regexp" | |
| 3542 | + }, | |
| 3543 | + "1": { | |
| 3544 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 3545 | + } | |
| 3546 | + }, | |
| 3547 | + "endCaptures": { | |
| 3548 | + "1": { | |
| 3549 | + "name": "keyword.operator.lookbehind.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 3550 | + }, | |
| 3551 | + "2": { | |
| 3552 | + "name": "invalid.illegal.newline.python" | |
| 3553 | + } | |
| 3554 | + }, | |
| 3555 | + "patterns": [ | |
| 3556 | + { | |
| 3557 | + "include": "#single-one-fregexp-expression" | |
| 3558 | + } | |
| 3559 | + ] | |
| 3560 | + }, | |
| 3561 | + "single-one-fregexp-lookbehind-negative": { | |
| 3562 | + "begin": "(\\()\\?<!", | |
| 3563 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3564 | + "beginCaptures": { | |
| 3565 | + "0": { | |
| 3566 | + "name": "keyword.operator.lookbehind.negative.regexp" | |
| 3567 | + }, | |
| 3568 | + "1": { | |
| 3569 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 3570 | + } | |
| 3571 | + }, | |
| 3572 | + "endCaptures": { | |
| 3573 | + "1": { | |
| 3574 | + "name": "keyword.operator.lookbehind.negative.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 3575 | + }, | |
| 3576 | + "2": { | |
| 3577 | + "name": "invalid.illegal.newline.python" | |
| 3578 | + } | |
| 3579 | + }, | |
| 3580 | + "patterns": [ | |
| 3581 | + { | |
| 3582 | + "include": "#single-one-fregexp-expression" | |
| 3583 | + } | |
| 3584 | + ] | |
| 3585 | + }, | |
| 3586 | + "single-one-fregexp-conditional": { | |
| 3587 | + "begin": "(\\()\\?\\((\\w+(?:\\s+[[:alnum:]]+)?|\\d+)\\)", | |
| 3588 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3589 | + "beginCaptures": { | |
| 3590 | + "0": { | |
| 3591 | + "name": "keyword.operator.conditional.regexp" | |
| 3592 | + }, | |
| 3593 | + "1": { | |
| 3594 | + "name": "punctuation.parenthesis.conditional.begin.regexp" | |
| 3595 | + } | |
| 3596 | + }, | |
| 3597 | + "endCaptures": { | |
| 3598 | + "1": { | |
| 3599 | + "name": "keyword.operator.conditional.negative.regexp punctuation.parenthesis.conditional.end.regexp" | |
| 3600 | + }, | |
| 3601 | + "2": { | |
| 3602 | + "name": "invalid.illegal.newline.python" | |
| 3603 | + } | |
| 3604 | + }, | |
| 3605 | + "patterns": [ | |
| 3606 | + { | |
| 3607 | + "include": "#single-one-fregexp-expression" | |
| 3608 | + } | |
| 3609 | + ] | |
| 3610 | + }, | |
| 3611 | + "single-one-fregexp-parentheses-non-capturing": { | |
| 3612 | + "begin": "\\(\\?:", | |
| 3613 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3614 | + "beginCaptures": { | |
| 3615 | + "0": { | |
| 3616 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.begin.regexp" | |
| 3617 | + } | |
| 3618 | + }, | |
| 3619 | + "endCaptures": { | |
| 3620 | + "1": { | |
| 3621 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.end.regexp" | |
| 3622 | + }, | |
| 3623 | + "2": { | |
| 3624 | + "name": "invalid.illegal.newline.python" | |
| 3625 | + } | |
| 3626 | + }, | |
| 3627 | + "patterns": [ | |
| 3628 | + { | |
| 3629 | + "include": "#single-one-fregexp-expression" | |
| 3630 | + } | |
| 3631 | + ] | |
| 3632 | + }, | |
| 3633 | + "single-one-fregexp-parentheses": { | |
| 3634 | + "begin": "\\(", | |
| 3635 | + "end": "(\\)|(?=\\'))|((?=(?<!\\\\)\\n))", | |
| 3636 | + "beginCaptures": { | |
| 3637 | + "0": { | |
| 3638 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.begin.regexp" | |
| 3639 | + } | |
| 3640 | + }, | |
| 3641 | + "endCaptures": { | |
| 3642 | + "1": { | |
| 3643 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.end.regexp" | |
| 3644 | + }, | |
| 3645 | + "2": { | |
| 3646 | + "name": "invalid.illegal.newline.python" | |
| 3647 | + } | |
| 3648 | + }, | |
| 3649 | + "patterns": [ | |
| 3650 | + { | |
| 3651 | + "include": "#single-one-fregexp-expression" | |
| 3652 | + } | |
| 3653 | + ] | |
| 3654 | + }, | |
| 3655 | + "single-three-fregexp-expression": { | |
| 3656 | + "patterns": [ | |
| 3657 | + { | |
| 3658 | + "include": "#fregexp-base-expression" | |
| 3659 | + }, | |
| 3660 | + { | |
| 3661 | + "include": "#single-three-regexp-character-set" | |
| 3662 | + }, | |
| 3663 | + { | |
| 3664 | + "include": "#single-three-regexp-comments" | |
| 3665 | + }, | |
| 3666 | + { | |
| 3667 | + "include": "#regexp-flags" | |
| 3668 | + }, | |
| 3669 | + { | |
| 3670 | + "include": "#single-three-regexp-named-group" | |
| 3671 | + }, | |
| 3672 | + { | |
| 3673 | + "include": "#regexp-backreference" | |
| 3674 | + }, | |
| 3675 | + { | |
| 3676 | + "include": "#single-three-fregexp-lookahead" | |
| 3677 | + }, | |
| 3678 | + { | |
| 3679 | + "include": "#single-three-fregexp-lookahead-negative" | |
| 3680 | + }, | |
| 3681 | + { | |
| 3682 | + "include": "#single-three-fregexp-lookbehind" | |
| 3683 | + }, | |
| 3684 | + { | |
| 3685 | + "include": "#single-three-fregexp-lookbehind-negative" | |
| 3686 | + }, | |
| 3687 | + { | |
| 3688 | + "include": "#single-three-fregexp-conditional" | |
| 3689 | + }, | |
| 3690 | + { | |
| 3691 | + "include": "#single-three-fregexp-parentheses-non-capturing" | |
| 3692 | + }, | |
| 3693 | + { | |
| 3694 | + "include": "#single-three-fregexp-parentheses" | |
| 3695 | + }, | |
| 3696 | + { | |
| 3697 | + "include": "#comments-string-single-three" | |
| 3698 | + } | |
| 3699 | + ] | |
| 3700 | + }, | |
| 3701 | + "single-three-fregexp-named-group": { | |
| 3702 | + "name": "meta.named.regexp", | |
| 3703 | + "begin": "(?x)\n (\\() (\\?P <\\w+(?:\\s+[[:alnum:]]+)?>)\n", | |
| 3704 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3705 | + "beginCaptures": { | |
| 3706 | + "1": { | |
| 3707 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.begin.regexp" | |
| 3708 | + }, | |
| 3709 | + "2": { | |
| 3710 | + "name": "entity.name.tag.named.group.regexp" | |
| 3711 | + } | |
| 3712 | + }, | |
| 3713 | + "endCaptures": { | |
| 3714 | + "1": { | |
| 3715 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.end.regexp" | |
| 3716 | + }, | |
| 3717 | + "2": { | |
| 3718 | + "name": "invalid.illegal.newline.python" | |
| 3719 | + } | |
| 3720 | + }, | |
| 3721 | + "patterns": [ | |
| 3722 | + { | |
| 3723 | + "include": "#single-three-fregexp-expression" | |
| 3724 | + }, | |
| 3725 | + { | |
| 3726 | + "include": "#comments-string-single-three" | |
| 3727 | + } | |
| 3728 | + ] | |
| 3729 | + }, | |
| 3730 | + "single-three-fregexp-lookahead": { | |
| 3731 | + "begin": "(\\()\\?=", | |
| 3732 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3733 | + "beginCaptures": { | |
| 3734 | + "0": { | |
| 3735 | + "name": "keyword.operator.lookahead.regexp" | |
| 3736 | + }, | |
| 3737 | + "1": { | |
| 3738 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 3739 | + } | |
| 3740 | + }, | |
| 3741 | + "endCaptures": { | |
| 3742 | + "1": { | |
| 3743 | + "name": "keyword.operator.lookahead.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 3744 | + }, | |
| 3745 | + "2": { | |
| 3746 | + "name": "invalid.illegal.newline.python" | |
| 3747 | + } | |
| 3748 | + }, | |
| 3749 | + "patterns": [ | |
| 3750 | + { | |
| 3751 | + "include": "#single-three-fregexp-expression" | |
| 3752 | + }, | |
| 3753 | + { | |
| 3754 | + "include": "#comments-string-single-three" | |
| 3755 | + } | |
| 3756 | + ] | |
| 3757 | + }, | |
| 3758 | + "single-three-fregexp-lookahead-negative": { | |
| 3759 | + "begin": "(\\()\\?!", | |
| 3760 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3761 | + "beginCaptures": { | |
| 3762 | + "0": { | |
| 3763 | + "name": "keyword.operator.lookahead.negative.regexp" | |
| 3764 | + }, | |
| 3765 | + "1": { | |
| 3766 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 3767 | + } | |
| 3768 | + }, | |
| 3769 | + "endCaptures": { | |
| 3770 | + "1": { | |
| 3771 | + "name": "keyword.operator.lookahead.negative.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 3772 | + }, | |
| 3773 | + "2": { | |
| 3774 | + "name": "invalid.illegal.newline.python" | |
| 3775 | + } | |
| 3776 | + }, | |
| 3777 | + "patterns": [ | |
| 3778 | + { | |
| 3779 | + "include": "#single-three-fregexp-expression" | |
| 3780 | + }, | |
| 3781 | + { | |
| 3782 | + "include": "#comments-string-single-three" | |
| 3783 | + } | |
| 3784 | + ] | |
| 3785 | + }, | |
| 3786 | + "single-three-fregexp-lookbehind": { | |
| 3787 | + "begin": "(\\()\\?<=", | |
| 3788 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3789 | + "beginCaptures": { | |
| 3790 | + "0": { | |
| 3791 | + "name": "keyword.operator.lookbehind.regexp" | |
| 3792 | + }, | |
| 3793 | + "1": { | |
| 3794 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 3795 | + } | |
| 3796 | + }, | |
| 3797 | + "endCaptures": { | |
| 3798 | + "1": { | |
| 3799 | + "name": "keyword.operator.lookbehind.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 3800 | + }, | |
| 3801 | + "2": { | |
| 3802 | + "name": "invalid.illegal.newline.python" | |
| 3803 | + } | |
| 3804 | + }, | |
| 3805 | + "patterns": [ | |
| 3806 | + { | |
| 3807 | + "include": "#single-three-fregexp-expression" | |
| 3808 | + }, | |
| 3809 | + { | |
| 3810 | + "include": "#comments-string-single-three" | |
| 3811 | + } | |
| 3812 | + ] | |
| 3813 | + }, | |
| 3814 | + "single-three-fregexp-lookbehind-negative": { | |
| 3815 | + "begin": "(\\()\\?<!", | |
| 3816 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3817 | + "beginCaptures": { | |
| 3818 | + "0": { | |
| 3819 | + "name": "keyword.operator.lookbehind.negative.regexp" | |
| 3820 | + }, | |
| 3821 | + "1": { | |
| 3822 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 3823 | + } | |
| 3824 | + }, | |
| 3825 | + "endCaptures": { | |
| 3826 | + "1": { | |
| 3827 | + "name": "keyword.operator.lookbehind.negative.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 3828 | + }, | |
| 3829 | + "2": { | |
| 3830 | + "name": "invalid.illegal.newline.python" | |
| 3831 | + } | |
| 3832 | + }, | |
| 3833 | + "patterns": [ | |
| 3834 | + { | |
| 3835 | + "include": "#single-three-fregexp-expression" | |
| 3836 | + }, | |
| 3837 | + { | |
| 3838 | + "include": "#comments-string-single-three" | |
| 3839 | + } | |
| 3840 | + ] | |
| 3841 | + }, | |
| 3842 | + "single-three-fregexp-conditional": { | |
| 3843 | + "begin": "(\\()\\?\\((\\w+(?:\\s+[[:alnum:]]+)?|\\d+)\\)", | |
| 3844 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3845 | + "beginCaptures": { | |
| 3846 | + "0": { | |
| 3847 | + "name": "keyword.operator.conditional.regexp" | |
| 3848 | + }, | |
| 3849 | + "1": { | |
| 3850 | + "name": "punctuation.parenthesis.conditional.begin.regexp" | |
| 3851 | + } | |
| 3852 | + }, | |
| 3853 | + "endCaptures": { | |
| 3854 | + "1": { | |
| 3855 | + "name": "keyword.operator.conditional.negative.regexp punctuation.parenthesis.conditional.end.regexp" | |
| 3856 | + }, | |
| 3857 | + "2": { | |
| 3858 | + "name": "invalid.illegal.newline.python" | |
| 3859 | + } | |
| 3860 | + }, | |
| 3861 | + "patterns": [ | |
| 3862 | + { | |
| 3863 | + "include": "#single-three-fregexp-expression" | |
| 3864 | + }, | |
| 3865 | + { | |
| 3866 | + "include": "#comments-string-single-three" | |
| 3867 | + } | |
| 3868 | + ] | |
| 3869 | + }, | |
| 3870 | + "single-three-fregexp-parentheses-non-capturing": { | |
| 3871 | + "begin": "\\(\\?:", | |
| 3872 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3873 | + "beginCaptures": { | |
| 3874 | + "0": { | |
| 3875 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.begin.regexp" | |
| 3876 | + } | |
| 3877 | + }, | |
| 3878 | + "endCaptures": { | |
| 3879 | + "1": { | |
| 3880 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.end.regexp" | |
| 3881 | + }, | |
| 3882 | + "2": { | |
| 3883 | + "name": "invalid.illegal.newline.python" | |
| 3884 | + } | |
| 3885 | + }, | |
| 3886 | + "patterns": [ | |
| 3887 | + { | |
| 3888 | + "include": "#single-three-fregexp-expression" | |
| 3889 | + }, | |
| 3890 | + { | |
| 3891 | + "include": "#comments-string-single-three" | |
| 3892 | + } | |
| 3893 | + ] | |
| 3894 | + }, | |
| 3895 | + "single-three-fregexp-parentheses": { | |
| 3896 | + "begin": "\\(", | |
| 3897 | + "end": "(\\)|(?=\\'\\'\\'))", | |
| 3898 | + "beginCaptures": { | |
| 3899 | + "0": { | |
| 3900 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.begin.regexp" | |
| 3901 | + } | |
| 3902 | + }, | |
| 3903 | + "endCaptures": { | |
| 3904 | + "1": { | |
| 3905 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.end.regexp" | |
| 3906 | + }, | |
| 3907 | + "2": { | |
| 3908 | + "name": "invalid.illegal.newline.python" | |
| 3909 | + } | |
| 3910 | + }, | |
| 3911 | + "patterns": [ | |
| 3912 | + { | |
| 3913 | + "include": "#single-three-fregexp-expression" | |
| 3914 | + }, | |
| 3915 | + { | |
| 3916 | + "include": "#comments-string-single-three" | |
| 3917 | + } | |
| 3918 | + ] | |
| 3919 | + }, | |
| 3920 | + "double-one-fregexp-expression": { | |
| 3921 | + "patterns": [ | |
| 3922 | + { | |
| 3923 | + "include": "#fregexp-base-expression" | |
| 3924 | + }, | |
| 3925 | + { | |
| 3926 | + "include": "#double-one-regexp-character-set" | |
| 3927 | + }, | |
| 3928 | + { | |
| 3929 | + "include": "#double-one-regexp-comments" | |
| 3930 | + }, | |
| 3931 | + { | |
| 3932 | + "include": "#regexp-flags" | |
| 3933 | + }, | |
| 3934 | + { | |
| 3935 | + "include": "#double-one-regexp-named-group" | |
| 3936 | + }, | |
| 3937 | + { | |
| 3938 | + "include": "#regexp-backreference" | |
| 3939 | + }, | |
| 3940 | + { | |
| 3941 | + "include": "#double-one-fregexp-lookahead" | |
| 3942 | + }, | |
| 3943 | + { | |
| 3944 | + "include": "#double-one-fregexp-lookahead-negative" | |
| 3945 | + }, | |
| 3946 | + { | |
| 3947 | + "include": "#double-one-fregexp-lookbehind" | |
| 3948 | + }, | |
| 3949 | + { | |
| 3950 | + "include": "#double-one-fregexp-lookbehind-negative" | |
| 3951 | + }, | |
| 3952 | + { | |
| 3953 | + "include": "#double-one-fregexp-conditional" | |
| 3954 | + }, | |
| 3955 | + { | |
| 3956 | + "include": "#double-one-fregexp-parentheses-non-capturing" | |
| 3957 | + }, | |
| 3958 | + { | |
| 3959 | + "include": "#double-one-fregexp-parentheses" | |
| 3960 | + } | |
| 3961 | + ] | |
| 3962 | + }, | |
| 3963 | + "double-one-fregexp-named-group": { | |
| 3964 | + "name": "meta.named.regexp", | |
| 3965 | + "begin": "(?x)\n (\\() (\\?P <\\w+(?:\\s+[[:alnum:]]+)?>)\n", | |
| 3966 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 3967 | + "beginCaptures": { | |
| 3968 | + "1": { | |
| 3969 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.begin.regexp" | |
| 3970 | + }, | |
| 3971 | + "2": { | |
| 3972 | + "name": "entity.name.tag.named.group.regexp" | |
| 3973 | + } | |
| 3974 | + }, | |
| 3975 | + "endCaptures": { | |
| 3976 | + "1": { | |
| 3977 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.end.regexp" | |
| 3978 | + }, | |
| 3979 | + "2": { | |
| 3980 | + "name": "invalid.illegal.newline.python" | |
| 3981 | + } | |
| 3982 | + }, | |
| 3983 | + "patterns": [ | |
| 3984 | + { | |
| 3985 | + "include": "#double-one-fregexp-expression" | |
| 3986 | + } | |
| 3987 | + ] | |
| 3988 | + }, | |
| 3989 | + "double-one-fregexp-lookahead": { | |
| 3990 | + "begin": "(\\()\\?=", | |
| 3991 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 3992 | + "beginCaptures": { | |
| 3993 | + "0": { | |
| 3994 | + "name": "keyword.operator.lookahead.regexp" | |
| 3995 | + }, | |
| 3996 | + "1": { | |
| 3997 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 3998 | + } | |
| 3999 | + }, | |
| 4000 | + "endCaptures": { | |
| 4001 | + "1": { | |
| 4002 | + "name": "keyword.operator.lookahead.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 4003 | + }, | |
| 4004 | + "2": { | |
| 4005 | + "name": "invalid.illegal.newline.python" | |
| 4006 | + } | |
| 4007 | + }, | |
| 4008 | + "patterns": [ | |
| 4009 | + { | |
| 4010 | + "include": "#double-one-fregexp-expression" | |
| 4011 | + } | |
| 4012 | + ] | |
| 4013 | + }, | |
| 4014 | + "double-one-fregexp-lookahead-negative": { | |
| 4015 | + "begin": "(\\()\\?!", | |
| 4016 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4017 | + "beginCaptures": { | |
| 4018 | + "0": { | |
| 4019 | + "name": "keyword.operator.lookahead.negative.regexp" | |
| 4020 | + }, | |
| 4021 | + "1": { | |
| 4022 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 4023 | + } | |
| 4024 | + }, | |
| 4025 | + "endCaptures": { | |
| 4026 | + "1": { | |
| 4027 | + "name": "keyword.operator.lookahead.negative.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 4028 | + }, | |
| 4029 | + "2": { | |
| 4030 | + "name": "invalid.illegal.newline.python" | |
| 4031 | + } | |
| 4032 | + }, | |
| 4033 | + "patterns": [ | |
| 4034 | + { | |
| 4035 | + "include": "#double-one-fregexp-expression" | |
| 4036 | + } | |
| 4037 | + ] | |
| 4038 | + }, | |
| 4039 | + "double-one-fregexp-lookbehind": { | |
| 4040 | + "begin": "(\\()\\?<=", | |
| 4041 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4042 | + "beginCaptures": { | |
| 4043 | + "0": { | |
| 4044 | + "name": "keyword.operator.lookbehind.regexp" | |
| 4045 | + }, | |
| 4046 | + "1": { | |
| 4047 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 4048 | + } | |
| 4049 | + }, | |
| 4050 | + "endCaptures": { | |
| 4051 | + "1": { | |
| 4052 | + "name": "keyword.operator.lookbehind.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 4053 | + }, | |
| 4054 | + "2": { | |
| 4055 | + "name": "invalid.illegal.newline.python" | |
| 4056 | + } | |
| 4057 | + }, | |
| 4058 | + "patterns": [ | |
| 4059 | + { | |
| 4060 | + "include": "#double-one-fregexp-expression" | |
| 4061 | + } | |
| 4062 | + ] | |
| 4063 | + }, | |
| 4064 | + "double-one-fregexp-lookbehind-negative": { | |
| 4065 | + "begin": "(\\()\\?<!", | |
| 4066 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4067 | + "beginCaptures": { | |
| 4068 | + "0": { | |
| 4069 | + "name": "keyword.operator.lookbehind.negative.regexp" | |
| 4070 | + }, | |
| 4071 | + "1": { | |
| 4072 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 4073 | + } | |
| 4074 | + }, | |
| 4075 | + "endCaptures": { | |
| 4076 | + "1": { | |
| 4077 | + "name": "keyword.operator.lookbehind.negative.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 4078 | + }, | |
| 4079 | + "2": { | |
| 4080 | + "name": "invalid.illegal.newline.python" | |
| 4081 | + } | |
| 4082 | + }, | |
| 4083 | + "patterns": [ | |
| 4084 | + { | |
| 4085 | + "include": "#double-one-fregexp-expression" | |
| 4086 | + } | |
| 4087 | + ] | |
| 4088 | + }, | |
| 4089 | + "double-one-fregexp-conditional": { | |
| 4090 | + "begin": "(\\()\\?\\((\\w+(?:\\s+[[:alnum:]]+)?|\\d+)\\)", | |
| 4091 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4092 | + "beginCaptures": { | |
| 4093 | + "0": { | |
| 4094 | + "name": "keyword.operator.conditional.regexp" | |
| 4095 | + }, | |
| 4096 | + "1": { | |
| 4097 | + "name": "punctuation.parenthesis.conditional.begin.regexp" | |
| 4098 | + } | |
| 4099 | + }, | |
| 4100 | + "endCaptures": { | |
| 4101 | + "1": { | |
| 4102 | + "name": "keyword.operator.conditional.negative.regexp punctuation.parenthesis.conditional.end.regexp" | |
| 4103 | + }, | |
| 4104 | + "2": { | |
| 4105 | + "name": "invalid.illegal.newline.python" | |
| 4106 | + } | |
| 4107 | + }, | |
| 4108 | + "patterns": [ | |
| 4109 | + { | |
| 4110 | + "include": "#double-one-fregexp-expression" | |
| 4111 | + } | |
| 4112 | + ] | |
| 4113 | + }, | |
| 4114 | + "double-one-fregexp-parentheses-non-capturing": { | |
| 4115 | + "begin": "\\(\\?:", | |
| 4116 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4117 | + "beginCaptures": { | |
| 4118 | + "0": { | |
| 4119 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.begin.regexp" | |
| 4120 | + } | |
| 4121 | + }, | |
| 4122 | + "endCaptures": { | |
| 4123 | + "1": { | |
| 4124 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.end.regexp" | |
| 4125 | + }, | |
| 4126 | + "2": { | |
| 4127 | + "name": "invalid.illegal.newline.python" | |
| 4128 | + } | |
| 4129 | + }, | |
| 4130 | + "patterns": [ | |
| 4131 | + { | |
| 4132 | + "include": "#double-one-fregexp-expression" | |
| 4133 | + } | |
| 4134 | + ] | |
| 4135 | + }, | |
| 4136 | + "double-one-fregexp-parentheses": { | |
| 4137 | + "begin": "\\(", | |
| 4138 | + "end": "(\\)|(?=\"))|((?=(?<!\\\\)\\n))", | |
| 4139 | + "beginCaptures": { | |
| 4140 | + "0": { | |
| 4141 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.begin.regexp" | |
| 4142 | + } | |
| 4143 | + }, | |
| 4144 | + "endCaptures": { | |
| 4145 | + "1": { | |
| 4146 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.end.regexp" | |
| 4147 | + }, | |
| 4148 | + "2": { | |
| 4149 | + "name": "invalid.illegal.newline.python" | |
| 4150 | + } | |
| 4151 | + }, | |
| 4152 | + "patterns": [ | |
| 4153 | + { | |
| 4154 | + "include": "#double-one-fregexp-expression" | |
| 4155 | + } | |
| 4156 | + ] | |
| 4157 | + }, | |
| 4158 | + "double-three-fregexp-expression": { | |
| 4159 | + "patterns": [ | |
| 4160 | + { | |
| 4161 | + "include": "#fregexp-base-expression" | |
| 4162 | + }, | |
| 4163 | + { | |
| 4164 | + "include": "#double-three-regexp-character-set" | |
| 4165 | + }, | |
| 4166 | + { | |
| 4167 | + "include": "#double-three-regexp-comments" | |
| 4168 | + }, | |
| 4169 | + { | |
| 4170 | + "include": "#regexp-flags" | |
| 4171 | + }, | |
| 4172 | + { | |
| 4173 | + "include": "#double-three-regexp-named-group" | |
| 4174 | + }, | |
| 4175 | + { | |
| 4176 | + "include": "#regexp-backreference" | |
| 4177 | + }, | |
| 4178 | + { | |
| 4179 | + "include": "#double-three-fregexp-lookahead" | |
| 4180 | + }, | |
| 4181 | + { | |
| 4182 | + "include": "#double-three-fregexp-lookahead-negative" | |
| 4183 | + }, | |
| 4184 | + { | |
| 4185 | + "include": "#double-three-fregexp-lookbehind" | |
| 4186 | + }, | |
| 4187 | + { | |
| 4188 | + "include": "#double-three-fregexp-lookbehind-negative" | |
| 4189 | + }, | |
| 4190 | + { | |
| 4191 | + "include": "#double-three-fregexp-conditional" | |
| 4192 | + }, | |
| 4193 | + { | |
| 4194 | + "include": "#double-three-fregexp-parentheses-non-capturing" | |
| 4195 | + }, | |
| 4196 | + { | |
| 4197 | + "include": "#double-three-fregexp-parentheses" | |
| 4198 | + }, | |
| 4199 | + { | |
| 4200 | + "include": "#comments-string-double-three" | |
| 4201 | + } | |
| 4202 | + ] | |
| 4203 | + }, | |
| 4204 | + "double-three-fregexp-named-group": { | |
| 4205 | + "name": "meta.named.regexp", | |
| 4206 | + "begin": "(?x)\n (\\() (\\?P <\\w+(?:\\s+[[:alnum:]]+)?>)\n", | |
| 4207 | + "end": "(\\)|(?=\"\"\"))", | |
| 4208 | + "beginCaptures": { | |
| 4209 | + "1": { | |
| 4210 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.begin.regexp" | |
| 4211 | + }, | |
| 4212 | + "2": { | |
| 4213 | + "name": "entity.name.tag.named.group.regexp" | |
| 4214 | + } | |
| 4215 | + }, | |
| 4216 | + "endCaptures": { | |
| 4217 | + "1": { | |
| 4218 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.named.end.regexp" | |
| 4219 | + }, | |
| 4220 | + "2": { | |
| 4221 | + "name": "invalid.illegal.newline.python" | |
| 4222 | + } | |
| 4223 | + }, | |
| 4224 | + "patterns": [ | |
| 4225 | + { | |
| 4226 | + "include": "#double-three-fregexp-expression" | |
| 4227 | + }, | |
| 4228 | + { | |
| 4229 | + "include": "#comments-string-double-three" | |
| 4230 | + } | |
| 4231 | + ] | |
| 4232 | + }, | |
| 4233 | + "double-three-fregexp-lookahead": { | |
| 4234 | + "begin": "(\\()\\?=", | |
| 4235 | + "end": "(\\)|(?=\"\"\"))", | |
| 4236 | + "beginCaptures": { | |
| 4237 | + "0": { | |
| 4238 | + "name": "keyword.operator.lookahead.regexp" | |
| 4239 | + }, | |
| 4240 | + "1": { | |
| 4241 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 4242 | + } | |
| 4243 | + }, | |
| 4244 | + "endCaptures": { | |
| 4245 | + "1": { | |
| 4246 | + "name": "keyword.operator.lookahead.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 4247 | + }, | |
| 4248 | + "2": { | |
| 4249 | + "name": "invalid.illegal.newline.python" | |
| 4250 | + } | |
| 4251 | + }, | |
| 4252 | + "patterns": [ | |
| 4253 | + { | |
| 4254 | + "include": "#double-three-fregexp-expression" | |
| 4255 | + }, | |
| 4256 | + { | |
| 4257 | + "include": "#comments-string-double-three" | |
| 4258 | + } | |
| 4259 | + ] | |
| 4260 | + }, | |
| 4261 | + "double-three-fregexp-lookahead-negative": { | |
| 4262 | + "begin": "(\\()\\?!", | |
| 4263 | + "end": "(\\)|(?=\"\"\"))", | |
| 4264 | + "beginCaptures": { | |
| 4265 | + "0": { | |
| 4266 | + "name": "keyword.operator.lookahead.negative.regexp" | |
| 4267 | + }, | |
| 4268 | + "1": { | |
| 4269 | + "name": "punctuation.parenthesis.lookahead.begin.regexp" | |
| 4270 | + } | |
| 4271 | + }, | |
| 4272 | + "endCaptures": { | |
| 4273 | + "1": { | |
| 4274 | + "name": "keyword.operator.lookahead.negative.regexp punctuation.parenthesis.lookahead.end.regexp" | |
| 4275 | + }, | |
| 4276 | + "2": { | |
| 4277 | + "name": "invalid.illegal.newline.python" | |
| 4278 | + } | |
| 4279 | + }, | |
| 4280 | + "patterns": [ | |
| 4281 | + { | |
| 4282 | + "include": "#double-three-fregexp-expression" | |
| 4283 | + }, | |
| 4284 | + { | |
| 4285 | + "include": "#comments-string-double-three" | |
| 4286 | + } | |
| 4287 | + ] | |
| 4288 | + }, | |
| 4289 | + "double-three-fregexp-lookbehind": { | |
| 4290 | + "begin": "(\\()\\?<=", | |
| 4291 | + "end": "(\\)|(?=\"\"\"))", | |
| 4292 | + "beginCaptures": { | |
| 4293 | + "0": { | |
| 4294 | + "name": "keyword.operator.lookbehind.regexp" | |
| 4295 | + }, | |
| 4296 | + "1": { | |
| 4297 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 4298 | + } | |
| 4299 | + }, | |
| 4300 | + "endCaptures": { | |
| 4301 | + "1": { | |
| 4302 | + "name": "keyword.operator.lookbehind.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 4303 | + }, | |
| 4304 | + "2": { | |
| 4305 | + "name": "invalid.illegal.newline.python" | |
| 4306 | + } | |
| 4307 | + }, | |
| 4308 | + "patterns": [ | |
| 4309 | + { | |
| 4310 | + "include": "#double-three-fregexp-expression" | |
| 4311 | + }, | |
| 4312 | + { | |
| 4313 | + "include": "#comments-string-double-three" | |
| 4314 | + } | |
| 4315 | + ] | |
| 4316 | + }, | |
| 4317 | + "double-three-fregexp-lookbehind-negative": { | |
| 4318 | + "begin": "(\\()\\?<!", | |
| 4319 | + "end": "(\\)|(?=\"\"\"))", | |
| 4320 | + "beginCaptures": { | |
| 4321 | + "0": { | |
| 4322 | + "name": "keyword.operator.lookbehind.negative.regexp" | |
| 4323 | + }, | |
| 4324 | + "1": { | |
| 4325 | + "name": "punctuation.parenthesis.lookbehind.begin.regexp" | |
| 4326 | + } | |
| 4327 | + }, | |
| 4328 | + "endCaptures": { | |
| 4329 | + "1": { | |
| 4330 | + "name": "keyword.operator.lookbehind.negative.regexp punctuation.parenthesis.lookbehind.end.regexp" | |
| 4331 | + }, | |
| 4332 | + "2": { | |
| 4333 | + "name": "invalid.illegal.newline.python" | |
| 4334 | + } | |
| 4335 | + }, | |
| 4336 | + "patterns": [ | |
| 4337 | + { | |
| 4338 | + "include": "#double-three-fregexp-expression" | |
| 4339 | + }, | |
| 4340 | + { | |
| 4341 | + "include": "#comments-string-double-three" | |
| 4342 | + } | |
| 4343 | + ] | |
| 4344 | + }, | |
| 4345 | + "double-three-fregexp-conditional": { | |
| 4346 | + "begin": "(\\()\\?\\((\\w+(?:\\s+[[:alnum:]]+)?|\\d+)\\)", | |
| 4347 | + "end": "(\\)|(?=\"\"\"))", | |
| 4348 | + "beginCaptures": { | |
| 4349 | + "0": { | |
| 4350 | + "name": "keyword.operator.conditional.regexp" | |
| 4351 | + }, | |
| 4352 | + "1": { | |
| 4353 | + "name": "punctuation.parenthesis.conditional.begin.regexp" | |
| 4354 | + } | |
| 4355 | + }, | |
| 4356 | + "endCaptures": { | |
| 4357 | + "1": { | |
| 4358 | + "name": "keyword.operator.conditional.negative.regexp punctuation.parenthesis.conditional.end.regexp" | |
| 4359 | + }, | |
| 4360 | + "2": { | |
| 4361 | + "name": "invalid.illegal.newline.python" | |
| 4362 | + } | |
| 4363 | + }, | |
| 4364 | + "patterns": [ | |
| 4365 | + { | |
| 4366 | + "include": "#double-three-fregexp-expression" | |
| 4367 | + }, | |
| 4368 | + { | |
| 4369 | + "include": "#comments-string-double-three" | |
| 4370 | + } | |
| 4371 | + ] | |
| 4372 | + }, | |
| 4373 | + "double-three-fregexp-parentheses-non-capturing": { | |
| 4374 | + "begin": "\\(\\?:", | |
| 4375 | + "end": "(\\)|(?=\"\"\"))", | |
| 4376 | + "beginCaptures": { | |
| 4377 | + "0": { | |
| 4378 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.begin.regexp" | |
| 4379 | + } | |
| 4380 | + }, | |
| 4381 | + "endCaptures": { | |
| 4382 | + "1": { | |
| 4383 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.non-capturing.end.regexp" | |
| 4384 | + }, | |
| 4385 | + "2": { | |
| 4386 | + "name": "invalid.illegal.newline.python" | |
| 4387 | + } | |
| 4388 | + }, | |
| 4389 | + "patterns": [ | |
| 4390 | + { | |
| 4391 | + "include": "#double-three-fregexp-expression" | |
| 4392 | + }, | |
| 4393 | + { | |
| 4394 | + "include": "#comments-string-double-three" | |
| 4395 | + } | |
| 4396 | + ] | |
| 4397 | + }, | |
| 4398 | + "double-three-fregexp-parentheses": { | |
| 4399 | + "begin": "\\(", | |
| 4400 | + "end": "(\\)|(?=\"\"\"))", | |
| 4401 | + "beginCaptures": { | |
| 4402 | + "0": { | |
| 4403 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.begin.regexp" | |
| 4404 | + } | |
| 4405 | + }, | |
| 4406 | + "endCaptures": { | |
| 4407 | + "1": { | |
| 4408 | + "name": "support.other.parenthesis.regexp punctuation.parenthesis.end.regexp" | |
| 4409 | + }, | |
| 4410 | + "2": { | |
| 4411 | + "name": "invalid.illegal.newline.python" | |
| 4412 | + } | |
| 4413 | + }, | |
| 4414 | + "patterns": [ | |
| 4415 | + { | |
| 4416 | + "include": "#double-three-fregexp-expression" | |
| 4417 | + }, | |
| 4418 | + { | |
| 4419 | + "include": "#comments-string-double-three" | |
| 4420 | + } | |
| 4421 | + ] | |
| 4422 | + }, | |
| 4423 | + "fregexp-single-one-line": { | |
| 4424 | + "name": "string.interpolated.python string.regexp.quoted.single.python", | |
| 4425 | + "begin": "\\b(([uU]r)|([fF]r)|(r[fF]?))(\\')", | |
| 4426 | + "end": "(\\')|(?<!\\\\)(\\n)", | |
| 4427 | + "beginCaptures": { | |
| 4428 | + "2": { | |
| 4429 | + "name": "invalid.deprecated.prefix.python" | |
| 4430 | + }, | |
| 4431 | + "3": { | |
| 4432 | + "name": "storage.type.string.python" | |
| 4433 | + }, | |
| 4434 | + "4": { | |
| 4435 | + "name": "storage.type.string.python" | |
| 4436 | + }, | |
| 4437 | + "5": { | |
| 4438 | + "name": "punctuation.definition.string.begin.python" | |
| 4439 | + } | |
| 4440 | + }, | |
| 4441 | + "endCaptures": { | |
| 4442 | + "1": { | |
| 4443 | + "name": "punctuation.definition.string.end.python" | |
| 4444 | + }, | |
| 4445 | + "2": { | |
| 4446 | + "name": "invalid.illegal.newline.python" | |
| 4447 | + } | |
| 4448 | + }, | |
| 4449 | + "patterns": [ | |
| 4450 | + { | |
| 4451 | + "include": "#single-one-fregexp-expression" | |
| 4452 | + } | |
| 4453 | + ] | |
| 4454 | + }, | |
| 4455 | + "fregexp-single-three-line": { | |
| 4456 | + "name": "string.interpolated.python string.regexp.quoted.multi.python", | |
| 4457 | + "begin": "\\b(([uU]r)|([fF]r)|(r[fF]?))(\\'\\'\\')", | |
| 4458 | + "end": "(\\'\\'\\')", | |
| 4459 | + "beginCaptures": { | |
| 4460 | + "2": { | |
| 4461 | + "name": "invalid.deprecated.prefix.python" | |
| 4462 | + }, | |
| 4463 | + "3": { | |
| 4464 | + "name": "storage.type.string.python" | |
| 4465 | + }, | |
| 4466 | + "4": { | |
| 4467 | + "name": "storage.type.string.python" | |
| 4468 | + }, | |
| 4469 | + "5": { | |
| 4470 | + "name": "punctuation.definition.string.begin.python" | |
| 4471 | + } | |
| 4472 | + }, | |
| 4473 | + "endCaptures": { | |
| 4474 | + "1": { | |
| 4475 | + "name": "punctuation.definition.string.end.python" | |
| 4476 | + }, | |
| 4477 | + "2": { | |
| 4478 | + "name": "invalid.illegal.newline.python" | |
| 4479 | + } | |
| 4480 | + }, | |
| 4481 | + "patterns": [ | |
| 4482 | + { | |
| 4483 | + "include": "#single-three-fregexp-expression" | |
| 4484 | + } | |
| 4485 | + ] | |
| 4486 | + }, | |
| 4487 | + "fregexp-double-one-line": { | |
| 4488 | + "name": "string.interpolated.python string.regexp.quoted.single.python", | |
| 4489 | + "begin": "\\b(([uU]r)|([fF]r)|(r[fF]?))(\")", | |
| 4490 | + "end": "(\")|(?<!\\\\)(\\n)", | |
| 4491 | + "beginCaptures": { | |
| 4492 | + "2": { | |
| 4493 | + "name": "invalid.deprecated.prefix.python" | |
| 4494 | + }, | |
| 4495 | + "3": { | |
| 4496 | + "name": "storage.type.string.python" | |
| 4497 | + }, | |
| 4498 | + "4": { | |
| 4499 | + "name": "storage.type.string.python" | |
| 4500 | + }, | |
| 4501 | + "5": { | |
| 4502 | + "name": "punctuation.definition.string.begin.python" | |
| 4503 | + } | |
| 4504 | + }, | |
| 4505 | + "endCaptures": { | |
| 4506 | + "1": { | |
| 4507 | + "name": "punctuation.definition.string.end.python" | |
| 4508 | + }, | |
| 4509 | + "2": { | |
| 4510 | + "name": "invalid.illegal.newline.python" | |
| 4511 | + } | |
| 4512 | + }, | |
| 4513 | + "patterns": [ | |
| 4514 | + { | |
| 4515 | + "include": "#double-one-fregexp-expression" | |
| 4516 | + } | |
| 4517 | + ] | |
| 4518 | + }, | |
| 4519 | + "fregexp-double-three-line": { | |
| 4520 | + "name": "string.interpolated.python string.regexp.quoted.multi.python", | |
| 4521 | + "begin": "\\b(([uU]r)|([fF]r)|(r[fF]?))(\"\"\")", | |
| 4522 | + "end": "(\"\"\")", | |
| 4523 | + "beginCaptures": { | |
| 4524 | + "2": { | |
| 4525 | + "name": "invalid.deprecated.prefix.python" | |
| 4526 | + }, | |
| 4527 | + "3": { | |
| 4528 | + "name": "storage.type.string.python" | |
| 4529 | + }, | |
| 4530 | + "4": { | |
| 4531 | + "name": "storage.type.string.python" | |
| 4532 | + }, | |
| 4533 | + "5": { | |
| 4534 | + "name": "punctuation.definition.string.begin.python" | |
| 4535 | + } | |
| 4536 | + }, | |
| 4537 | + "endCaptures": { | |
| 4538 | + "1": { | |
| 4539 | + "name": "punctuation.definition.string.end.python" | |
| 4540 | + }, | |
| 4541 | + "2": { | |
| 4542 | + "name": "invalid.illegal.newline.python" | |
| 4543 | + } | |
| 4544 | + }, | |
| 4545 | + "patterns": [ | |
| 4546 | + { | |
| 4547 | + "include": "#double-three-fregexp-expression" | |
| 4548 | + } | |
| 4549 | + ] | |
| 4550 | + }, | |
| 3424 | 4551 | "string-raw-quoted-single-line": { |
| 3425 | 4552 | "name": "string.quoted.raw.single.python", |
| 3426 | 4553 | "begin": "\\b(([uU]R)|(R))((['\"]))", |
| 3427 | 4554 | "end": "(\\4)|((?<!\\\\)\\n)", |
| @@ -3846,9 +4973,9 @@ | ||
| 3846 | 4973 | ] |
| 3847 | 4974 | }, |
| 3848 | 4975 | "fstring-raw-quoted-single-line": { |
| 3849 | 4976 | "name": "meta.fstring.python", |
| 3850 | - "begin": "(\\b(?:[rR][fF]|[fF][rR]))((['\"]))", | |
| 4977 | + "begin": "(\\b(?:[R][fF]|[fF][R]))((['\"]))", | |
| 3851 | 4978 | "end": "(\\2)|((?<!\\\\)\\n)", |
| 3852 | 4979 | "beginCaptures": { |
| 3853 | 4980 | "1": { |
| 3854 | 4981 | "name": "string.interpolated.python string.quoted.raw.single.python storage.type.string.python" |
| @@ -3914,16 +5041,12 @@ | ||
| 3914 | 5041 | "fstring-terminator-single": { |
| 3915 | 5042 | "patterns": [ |
| 3916 | 5043 | { |
| 3917 | 5044 | "name": "storage.type.format.python", |
| 3918 | - "match": "(=(![rsa])?)(?=})" | |
| 5045 | + "match": "(![rsa])(?=})" | |
| 3919 | 5046 | }, |
| 3920 | 5047 | { |
| 3921 | - "name": "storage.type.format.python", | |
| 3922 | - "match": "(=?![rsa])(?=})" | |
| 3923 | - }, | |
| 3924 | - { | |
| 3925 | - "match": "(?x)\n ( (?: =?) (?: ![rsa])? )\n ( : \\w? [<>=^]? [-+ ]? \\#?\n \\d* ,? (\\.\\d+)? [bcdeEfFgGnosxX%]? )(?=})\n", | |
| 5048 | + "match": "(?x)\n (![rsa])?\n ( : \\w? [<>=^]? [-+ ]? \\#?\n \\d* ,? (\\.\\d+)? [bcdeEfFgGnosxX%]? )(?=})\n", | |
| 3926 | 5049 | "captures": { |
| 3927 | 5050 | "1": { |
| 3928 | 5051 | "name": "storage.type.format.python" |
| 3929 | 5052 | }, |
| @@ -3937,9 +5060,9 @@ | ||
| 3937 | 5060 | } |
| 3938 | 5061 | ] |
| 3939 | 5062 | }, |
| 3940 | 5063 | "fstring-terminator-single-tail": { |
| 3941 | - "begin": "((?:=?)(?:![rsa])?)(:)(?=.*?{)", | |
| 5064 | + "begin": "(![rsa])?(:)(?=.*?{)", | |
| 3942 | 5065 | "end": "(?=})|(?=\\n)", |
| 3943 | 5066 | "beginCaptures": { |
| 3944 | 5067 | "1": { |
| 3945 | 5068 | "name": "storage.type.format.python" |
| @@ -4066,9 +5189,9 @@ | ||
| 4066 | 5189 | ] |
| 4067 | 5190 | }, |
| 4068 | 5191 | "fstring-raw-quoted-multi-line": { |
| 4069 | 5192 | "name": "meta.fstring.python", |
| 4070 | - "begin": "(\\b(?:[rR][fF]|[fF][rR]))('''|\"\"\")", | |
| 5193 | + "begin": "(\\b(?:[R][fF]|[fF][R]))('''|\"\"\")", | |
| 4071 | 5194 | "end": "(\\2)", |
| 4072 | 5195 | "beginCaptures": { |
| 4073 | 5196 | "1": { |
| 4074 | 5197 | "name": "string.interpolated.python string.quoted.raw.multi.python storage.type.string.python" |
| @@ -4134,16 +5257,12 @@ | ||
| 4134 | 5257 | "fstring-terminator-multi": { |
| 4135 | 5258 | "patterns": [ |
| 4136 | 5259 | { |
| 4137 | 5260 | "name": "storage.type.format.python", |
| 4138 | - "match": "(=(![rsa])?)(?=})" | |
| 5261 | + "match": "(![rsa])(?=})" | |
| 4139 | 5262 | }, |
| 4140 | 5263 | { |
| 4141 | - "name": "storage.type.format.python", | |
| 4142 | - "match": "(=?![rsa])(?=})" | |
| 4143 | - }, | |
| 4144 | - { | |
| 4145 | - "match": "(?x)\n ( (?: =?) (?: ![rsa])? )\n ( : \\w? [<>=^]? [-+ ]? \\#?\n \\d* ,? (\\.\\d+)? [bcdeEfFgGnosxX%]? )(?=})\n", | |
| 5264 | + "match": "(?x)\n (![rsa])?\n ( : \\w? [<>=^]? [-+ ]? \\#?\n \\d* ,? (\\.\\d+)? [bcdeEfFgGnosxX%]? )(?=})\n", | |
| 4146 | 5265 | "captures": { |
| 4147 | 5266 | "1": { |
| 4148 | 5267 | "name": "storage.type.format.python" |
| 4149 | 5268 | }, |
| @@ -4157,9 +5276,9 @@ | ||
| 4157 | 5276 | } |
| 4158 | 5277 | ] |
| 4159 | 5278 | }, |
| 4160 | 5279 | "fstring-terminator-multi-tail": { |
| 4161 | - "begin": "((?:=?)(?:![rsa])?)(:)(?=.*?{)", | |
| 5280 | + "begin": "(![rsa])?(:)(?=.*?{)", | |
| 4162 | 5281 | "end": "(?=})", |
| 4163 | 5282 | "beginCaptures": { |
| 4164 | 5283 | "1": { |
| 4165 | 5284 | "name": "storage.type.format.python" |