Skip to content

Commit e9bb8b3

Browse files
committed
do not autoclose quotes when in strings. Fixes microsoft#88265
1 parent 4f6af32 commit e9bb8b3

20 files changed

+56
-53
lines changed

extensions/bat/language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1515
],
1616
"surroundingPairs": [
1717
["{", "}"],

extensions/clojure/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1515
],
1616
"surroundingPairs": [
1717
["{", "}"],
@@ -22,4 +22,4 @@
2222
"folding": {
2323
"offSide": true
2424
}
25-
}
25+
}

extensions/coffeescript/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],

extensions/groovy/language-configuration.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],
@@ -22,4 +22,4 @@
2222
["\"", "\""],
2323
["'", "'"]
2424
]
25-
}
25+
}

extensions/ini/ini.language-configuration.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],
@@ -22,4 +22,4 @@
2222
["\"", "\""],
2323
["'", "'"]
2424
]
25-
}
25+
}

extensions/ini/properties.language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1616
],
1717
"surroundingPairs": [
1818
["{", "}"],
@@ -21,4 +21,4 @@
2121
["\"", "\""],
2222
["'", "'"]
2323
]
24-
}
24+
}

extensions/java/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"],
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] },
1717
{ "open": "/**", "close": " */", "notIn": ["string"] }
1818
],
1919
"surroundingPairs": [

extensions/lua/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],

extensions/objective-c/language-configuration.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],
@@ -22,4 +22,4 @@
2222
["\"", "\""],
2323
["'", "'"]
2424
]
25-
}
25+
}

extensions/perl/perl.language-configuration.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""],
15-
["'", "'"],
16-
["`", "`"]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
15+
{ "open": "'", "close": "'", "notIn": ["string"] },
16+
{ "open": "`", "close": "`", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],
@@ -29,4 +29,4 @@
2929
"end": "^(?:(?:=cut\\s*$)|(?:\\s*#endregion\\b))"
3030
}
3131
}
32-
}
32+
}

extensions/perl/perl6.language-configuration.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""],
15-
["'", "'"],
16-
["`", "`"]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
15+
{ "open": "'", "close": "'", "notIn": ["string"] },
16+
{ "open": "`", "close": "`", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],
@@ -23,4 +23,4 @@
2323
["'", "'"],
2424
["`", "`"]
2525
]
26-
}
26+
}

extensions/pug/language-configuration.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["'", "'"],
15-
["\"", "\""]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
15+
{ "open": "'", "close": "'", "notIn": ["string"] }
1616
],
1717
"surroundingPairs": [
1818
["{", "}"],
@@ -24,4 +24,4 @@
2424
"folding": {
2525
"offSide": true
2626
}
27-
}
27+
}

extensions/r/language-configuration.json

+5-3
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,14 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
15+
{ "open": "'", "close": "'", "notIn": ["string"] }
1516
],
1617
"surroundingPairs": [
1718
["{", "}"],
1819
["[", "]"],
1920
["(", ")"],
20-
["\"", "\""]
21+
["\"", "\""],
22+
["'", "'"]
2123
]
22-
}
24+
}

extensions/ruby/language-configuration.json

+5-3
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,17 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] },
17+
{ "open": "`", "close": "`", "notIn": ["string"] }
1718
],
1819
"surroundingPairs": [
1920
["{", "}"],
2021
["[", "]"],
2122
["(", ")"],
2223
["\"", "\""],
23-
["'", "'"]
24+
["'", "'"],
25+
["`", "`"]
2426
],
2527
"indentationRules": {
2628
"increaseIndentPattern": "^\\s*((begin|class|(private|protected)\\s+def|def|else|elsif|ensure|for|if|module|rescue|unless|until|when|while|case)|([^#]*\\sdo\\b)|([^#]*=\\s*(case|if|unless)))\\b([^#\\{;]|(\"|'|\/).*\\4)*(#.*)?$",

extensions/rust/language-configuration.json

+2-3
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,13 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1616
],
1717
"surroundingPairs": [
1818
["{", "}"],
1919
["[", "]"],
2020
["(", ")"],
21-
["\"", "\""],
22-
["'", "'"]
21+
["\"", "\""]
2322
],
2423
"indentationRules": {
2524
"increaseIndentPattern": "^.*\\{[^}\"']*$|^.*\\([^\\)\"']*$",

extensions/shaderlab/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1616
],
1717
"surroundingPairs": [
1818
["{", "}"],
1919
["[", "]"],
2020
["(", ")"],
2121
["\"", "\""]
2222
]
23-
}
23+
}

extensions/shellscript/language-configuration.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
["{", "}"],
1212
["[", "]"],
1313
["(", ")"],
14-
["\"", "\""],
15-
["'", "'"],
16-
["`", "`"]
14+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
15+
{ "open": "'", "close": "'", "notIn": ["string"] },
16+
{ "open": "`", "close": "`", "notIn": ["string"] }
1717
],
1818
"surroundingPairs": [
1919
["{", "}"],

extensions/swift/language-configuration.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""],
16-
["'", "'"],
17-
["`", "`"]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] },
17+
{ "open": "`", "close": "`", "notIn": ["string"] }
1818
],
1919
"surroundingPairs": [
2020
["{", "}"],
@@ -24,4 +24,4 @@
2424
["'", "'"],
2525
["`", "`"]
2626
]
27-
}
27+
}

extensions/vb/language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
["{", "}"],
1313
["[", "]"],
1414
["(", ")"],
15-
["\"", "\""]
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] }
1616
],
1717
"surroundingPairs": [
1818
["{", "}"],
@@ -27,4 +27,4 @@
2727
"end": "^\\s*#End Region\\b"
2828
}
2929
}
30-
}
30+
}

extensions/xml/xml.language-configuration.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
{ "open": "{", "close": "}"},
1313
{ "open": "[", "close": "]"},
1414
{ "open": "(", "close": ")" },
15-
{ "open": "'", "close": "'" },
16-
{ "open": "\"", "close": "\"" },
15+
{ "open": "\"", "close": "\"", "notIn": ["string"] },
16+
{ "open": "'", "close": "'", "notIn": ["string"] },
1717
{ "open": "<!--", "close": "-->", "notIn": [ "comment", "string" ]},
1818
{ "open": "<![CDATA[", "close": "]]>", "notIn": [ "comment", "string" ]}
1919
],

0 commit comments

Comments
 (0)