From ba737b58dc559e560295de9671cfe9bbf503a47b Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Sat, 12 Mar 2016 14:58:07 +0100 Subject: [PATCH] Update Typescript & JavaScript grammars with fix for TypeScript-TmLanguage/37 --- .../javascript/syntaxes/JavaScript.tmLanguage | 55 ++++++++++++------- .../typescript/syntaxes/TypeScript.tmLanguage | 55 ++++++++++++------- .../syntaxes/TypeScriptReact.tmLanguage | 55 ++++++++++++------- 3 files changed, 105 insertions(+), 60 deletions(-) diff --git a/extensions/javascript/syntaxes/JavaScript.tmLanguage b/extensions/javascript/syntaxes/JavaScript.tmLanguage index 25fe623480d..2df71e34a97 100644 --- a/extensions/javascript/syntaxes/JavaScript.tmLanguage +++ b/extensions/javascript/syntaxes/JavaScript.tmLanguage @@ -336,6 +336,10 @@ include #block + + include + #import-operator + include #expression-operator @@ -381,9 +385,9 @@ expression-operator match - =>|\b(delete|export|import|from|in|instanceof|new|typeof|void|as)\b + =>|\b(delete|in|instanceof|new|typeof|as|is|of)\b name - keyword.operator.js + keyword.others.js field-declaration @@ -399,7 +403,7 @@ 2 name - keyword.operator.js + keyword.others.js end @@ -426,7 +430,7 @@ 3 name - keyword.operator.js + keyword.others.js match @@ -463,7 +467,7 @@ 1 name - storage.modifier.js + storage.type.js 2 @@ -520,7 +524,7 @@ 1 name - storage.modifier.js + storage.type.js 2 @@ -582,6 +586,13 @@ + import-operator + + match + \b(import|from)\b + name + keyword.control.import.include.js + indexer-declaration begin @@ -606,7 +617,7 @@ 2 name - keyword.operator.js + keyword.others.js name @@ -1113,7 +1124,7 @@ 6 name - support.type.js + storage.type.js 7 @@ -1190,7 +1201,7 @@ 6 name - support.type.js + storage.type.js 7 @@ -1217,7 +1228,7 @@ 1 name - keyword.operator.js + keyword.others.js end @@ -1327,7 +1338,7 @@ 1 name - storage.modifier.js + storage.type.js 2 @@ -1478,7 +1489,7 @@ 2 name - keyword.operator.js + keyword.others.js 3 @@ -1488,7 +1499,7 @@ 4 name - keyword.operator.js + keyword.others.js match @@ -1622,7 +1633,7 @@ storage-keyword match - \b(var|let|function|const|module|namespace)\b + \b(var|let|function|const|module|namespace|void|export)\b name storage.type.js @@ -1674,7 +1685,7 @@ 1 name - keyword.operator.js + keyword.control.js end @@ -1770,7 +1781,7 @@ 0 name - keyword.operator.js + keyword.others.js end @@ -1780,7 +1791,7 @@ 0 name - keyword.operator.js + keyword.others.js name @@ -1850,6 +1861,10 @@ meta.type.annotation.js patterns + + include + #expression-operator + include #type @@ -1899,7 +1914,7 @@ match =\s* name - keyword.operator.js + keyword.operator.comparison.js @@ -1912,7 +1927,7 @@ 0 name - keyword.operator.js + keyword.others.js end @@ -2207,7 +2222,7 @@ 1 name - keyword.operator.js + keyword.others.js end diff --git a/extensions/typescript/syntaxes/TypeScript.tmLanguage b/extensions/typescript/syntaxes/TypeScript.tmLanguage index 026b83152dd..49b7b9c2c6f 100644 --- a/extensions/typescript/syntaxes/TypeScript.tmLanguage +++ b/extensions/typescript/syntaxes/TypeScript.tmLanguage @@ -367,6 +367,10 @@ include #block + + include + #import-operator + include #expression-operator @@ -412,9 +416,9 @@ expression-operator match - =>|\b(delete|export|import|from|in|instanceof|new|typeof|void|as)\b + =>|\b(delete|in|instanceof|new|typeof|as|is|of)\b name - keyword.operator.ts + keyword.others.ts field-declaration @@ -430,7 +434,7 @@ 2 name - keyword.operator.ts + keyword.others.ts end @@ -457,7 +461,7 @@ 3 name - keyword.operator.ts + keyword.others.ts match @@ -494,7 +498,7 @@ 1 name - storage.modifier.ts + storage.type.ts 2 @@ -551,7 +555,7 @@ 1 name - storage.modifier.ts + storage.type.ts 2 @@ -613,6 +617,13 @@ + import-operator + + match + \b(import|from)\b + name + keyword.control.import.include.ts + indexer-declaration begin @@ -637,7 +648,7 @@ 2 name - keyword.operator.ts + keyword.others.ts name @@ -746,7 +757,7 @@ 6 name - support.type.ts + storage.type.ts 7 @@ -823,7 +834,7 @@ 6 name - support.type.ts + storage.type.ts 7 @@ -850,7 +861,7 @@ 1 name - keyword.operator.ts + keyword.others.ts end @@ -960,7 +971,7 @@ 1 name - storage.modifier.ts + storage.type.ts 2 @@ -1111,7 +1122,7 @@ 2 name - keyword.operator.ts + keyword.others.ts 3 @@ -1121,7 +1132,7 @@ 4 name - keyword.operator.ts + keyword.others.ts match @@ -1255,7 +1266,7 @@ storage-keyword match - \b(var|let|function|const|module|namespace)\b + \b(var|let|function|const|module|namespace|void|export)\b name storage.type.ts @@ -1307,7 +1318,7 @@ 1 name - keyword.operator.ts + keyword.control.ts end @@ -1403,7 +1414,7 @@ 0 name - keyword.operator.ts + keyword.others.ts end @@ -1413,7 +1424,7 @@ 0 name - keyword.operator.ts + keyword.others.ts name @@ -1483,6 +1494,10 @@ meta.type.annotation.ts patterns + + include + #expression-operator + include #type @@ -1532,7 +1547,7 @@ match =\s* name - keyword.operator.ts + keyword.operator.comparison.ts @@ -1545,7 +1560,7 @@ 0 name - keyword.operator.ts + keyword.others.ts end @@ -1840,7 +1855,7 @@ 1 name - keyword.operator.ts + keyword.others.ts end diff --git a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage index 6ef5eae60f9..978fe9ea738 100644 --- a/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage +++ b/extensions/typescript/syntaxes/TypeScriptReact.tmLanguage @@ -335,6 +335,10 @@ include #block + + include + #import-operator + include #expression-operator @@ -380,9 +384,9 @@ expression-operator match - =>|\b(delete|export|import|from|in|instanceof|new|typeof|void|as)\b + =>|\b(delete|in|instanceof|new|typeof|as|is|of)\b name - keyword.operator.tsx + keyword.others.tsx field-declaration @@ -398,7 +402,7 @@ 2 name - keyword.operator.tsx + keyword.others.tsx end @@ -425,7 +429,7 @@ 3 name - keyword.operator.tsx + keyword.others.tsx match @@ -462,7 +466,7 @@ 1 name - storage.modifier.tsx + storage.type.tsx 2 @@ -519,7 +523,7 @@ 1 name - storage.modifier.tsx + storage.type.tsx 2 @@ -581,6 +585,13 @@ + import-operator + + match + \b(import|from)\b + name + keyword.control.import.include.tsx + indexer-declaration begin @@ -605,7 +616,7 @@ 2 name - keyword.operator.tsx + keyword.others.tsx name @@ -1112,7 +1123,7 @@ 6 name - support.type.tsx + storage.type.tsx 7 @@ -1189,7 +1200,7 @@ 6 name - support.type.tsx + storage.type.tsx 7 @@ -1216,7 +1227,7 @@ 1 name - keyword.operator.tsx + keyword.others.tsx end @@ -1326,7 +1337,7 @@ 1 name - storage.modifier.tsx + storage.type.tsx 2 @@ -1477,7 +1488,7 @@ 2 name - keyword.operator.tsx + keyword.others.tsx 3 @@ -1487,7 +1498,7 @@ 4 name - keyword.operator.tsx + keyword.others.tsx match @@ -1621,7 +1632,7 @@ storage-keyword match - \b(var|let|function|const|module|namespace)\b + \b(var|let|function|const|module|namespace|void|export)\b name storage.type.tsx @@ -1673,7 +1684,7 @@ 1 name - keyword.operator.tsx + keyword.control.tsx end @@ -1769,7 +1780,7 @@ 0 name - keyword.operator.tsx + keyword.others.tsx end @@ -1779,7 +1790,7 @@ 0 name - keyword.operator.tsx + keyword.others.tsx name @@ -1849,6 +1860,10 @@ meta.type.annotation.tsx patterns + + include + #expression-operator + include #type @@ -1898,7 +1913,7 @@ match =\s* name - keyword.operator.tsx + keyword.operator.comparison.tsx @@ -1911,7 +1926,7 @@ 0 name - keyword.operator.tsx + keyword.others.tsx end @@ -2206,7 +2221,7 @@ 1 name - keyword.operator.tsx + keyword.others.tsx end -- GitLab