@codingame/monaco-editor-wrapper 1.2.1 → 1.4.2
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/COBOL Copybook2.js +2017 -0
- package/dist/COBOL2.js +2017 -0
- package/dist/JavaScript.tmLanguage.js +22 -1
- package/dist/JavaScriptReact.tmLanguage.js +22 -1
- package/dist/SQL.plist.js +482 -0
- package/dist/TypeScript.tmLanguage.js +22 -1
- package/dist/TypeScriptReact.tmLanguage.js +22 -1
- package/dist/angular.js +56 -0
- package/dist/bsv2.js +49 -0
- package/dist/buildtarget.js +53 -0
- package/dist/c2.js +18 -0
- package/dist/clojure.tmLanguage.js +11 -15
- package/dist/cobol2.js +80 -0
- package/dist/coffeescript2.js +18 -0
- package/dist/configuration/hack.d.ts +2 -0
- package/dist/cpp2.js +18 -0
- package/dist/cpptools.js +2320 -0
- package/dist/csharp.tmLanguage.js +5 -5
- package/dist/csharp2.js +508 -0
- package/dist/d2.js +2 -66
- package/dist/d3.js +526 -0
- package/dist/dart3.js +966 -0
- package/dist/dcf.js +3 -3
- package/dist/diet3.js +92 -0
- package/dist/elixir3.js +40 -0
- package/dist/erlang2.js +92 -0
- package/dist/extensionConfigurations.js +1418 -1171
- package/dist/features/cssContribution.js +10 -0
- package/dist/features/extensionConfigurations.d.ts +1 -0
- package/dist/features/extensionConfigurations.js +145 -0
- package/dist/features/htmlContribution.js +10 -0
- package/dist/features/jsonContribution.js +84 -0
- package/dist/features/typescriptContribution.d.ts +4 -0
- package/dist/features/typescriptContribution.js +64 -0
- package/dist/fsharp.tmLanguage.js +10 -1
- package/dist/fsharp2.js +18 -0
- package/dist/groovy2.js +229 -0
- package/dist/haskell2.js +16 -0
- package/dist/html (eex).js +31 -0
- package/dist/java2.js +704 -0
- package/dist/javascript.js +83 -2
- package/dist/javascript2.js +196 -0
- package/dist/javascriptreact.js +83 -2
- package/dist/javascriptreact2.js +196 -0
- package/dist/jsonContribution.js +40 -46
- package/dist/jsx-tags.js +51 -2
- package/dist/jvm-bytecode-verbose.js +1231 -0
- package/dist/jvm-bytecode.js +565 -0
- package/dist/kotlin2.js +117 -0
- package/dist/kotlinscript2.js +117 -0
- package/dist/languages/extensions/configurationLoader.d.ts +1 -13
- package/dist/languages/extensions/extensionConfigurationLoader.d.ts +3 -0
- package/dist/languages/extensions/grammarLoader.d.ts +2 -101920
- package/dist/languages/extensions/languageConfigurationLoader.d.ts +3 -0
- package/dist/languages/extensions/snippetLoader.d.ts +3 -5606
- package/dist/languages/monarch/list.d.ts +7 -0
- package/dist/languages/textMate/TextMateTokensProvider.d.ts +11 -0
- package/dist/lua2.js +1511 -0
- package/dist/main.js +155 -98
- package/dist/markdown-basics.js +103 -0
- package/dist/markdown2.js +103 -0
- package/dist/ocaml3.js +145 -0
- package/dist/omnisharp.js +522 -0
- package/dist/pascal2.js +26 -0
- package/dist/pgsql-sql.js +21 -0
- package/dist/pgsql.js +21 -0
- package/dist/php2.js +265 -0
- package/dist/postgresql.js +75 -0
- package/dist/powershell2.js +18 -0
- package/dist/r.tmLanguage.js +572 -0
- package/dist/reason2.js +100 -0
- package/dist/rmd.js +8 -1
- package/dist/scalameta.js +177 -0
- package/dist/services/functional.d.ts +1 -0
- package/dist/services/lyfecycle.d.ts +13 -0
- package/dist/solargraph.js +192 -0
- package/dist/sql.js +9 -2
- package/dist/sql2.js +21 -0
- package/dist/swift2.js +183 -0
- package/dist/systemverilog2.js +208 -0
- package/dist/tasty.js +72 -0
- package/dist/tcl2.js +151 -0
- package/dist/typescript-basics.js +312 -0
- package/dist/typescript-language-features.js +998 -0
- package/dist/typescript.js +83 -2
- package/dist/typescript2.js +312 -0
- package/dist/typescriptreact.js +83 -2
- package/dist/typescriptreact2.js +312 -0
- package/dist/vb2.js +88 -0
- package/dist/verilog2.js +94 -0
- package/dist/vscode-R.js +519 -0
- package/dist/vscode-groovy.js +28 -0
- package/dist/vscode-python.js +677 -0
- package/package.json +11 -11
- package/stats.html +205 -795
|
@@ -3,7 +3,7 @@ var information_for_contributors = [
|
|
|
3
3
|
"If you want to provide a fix or improvement, please create a pull request against the original repository.",
|
|
4
4
|
"Once accepted there, we are happy to receive an update request."
|
|
5
5
|
];
|
|
6
|
-
var version = "https://github.com/dotnet/csharp-tmLanguage/commit/
|
|
6
|
+
var version = "https://github.com/dotnet/csharp-tmLanguage/commit/16612717ccd557383c0c821d7b6ae6662492ffde";
|
|
7
7
|
var name = "C#";
|
|
8
8
|
var scopeName = "source.cs";
|
|
9
9
|
var patterns = [
|
|
@@ -996,7 +996,7 @@ var repository = {
|
|
|
996
996
|
name: "keyword.other.where.cs"
|
|
997
997
|
},
|
|
998
998
|
"2": {
|
|
999
|
-
name: "
|
|
999
|
+
name: "entity.name.type.type-parameter.cs"
|
|
1000
1000
|
},
|
|
1001
1001
|
"3": {
|
|
1002
1002
|
name: "punctuation.separator.colon.cs"
|
|
@@ -4119,7 +4119,7 @@ var repository = {
|
|
|
4119
4119
|
match: "(@?[_[:alpha:]][_[:alnum:]]*)\\s*(\\.)",
|
|
4120
4120
|
captures: {
|
|
4121
4121
|
"1": {
|
|
4122
|
-
name: "
|
|
4122
|
+
name: "entity.name.type.cs"
|
|
4123
4123
|
},
|
|
4124
4124
|
"2": {
|
|
4125
4125
|
name: "punctuation.accessor.cs"
|
|
@@ -4133,12 +4133,12 @@ var repository = {
|
|
|
4133
4133
|
name: "punctuation.accessor.cs"
|
|
4134
4134
|
},
|
|
4135
4135
|
"2": {
|
|
4136
|
-
name: "
|
|
4136
|
+
name: "entity.name.type.cs"
|
|
4137
4137
|
}
|
|
4138
4138
|
}
|
|
4139
4139
|
},
|
|
4140
4140
|
{
|
|
4141
|
-
name: "
|
|
4141
|
+
name: "entity.name.type.cs",
|
|
4142
4142
|
match: "@?[_[:alpha:]][_[:alnum:]]*"
|
|
4143
4143
|
}
|
|
4144
4144
|
]
|
package/dist/csharp2.js
ADDED
|
@@ -0,0 +1,508 @@
|
|
|
1
|
+
var Class = {
|
|
2
|
+
prefix: "class",
|
|
3
|
+
body: [
|
|
4
|
+
"class ${1:Name}",
|
|
5
|
+
"{",
|
|
6
|
+
"\t$0",
|
|
7
|
+
"}"
|
|
8
|
+
],
|
|
9
|
+
description: "Class"
|
|
10
|
+
};
|
|
11
|
+
var Enum = {
|
|
12
|
+
prefix: "enum",
|
|
13
|
+
body: [
|
|
14
|
+
"enum ${1:Name}",
|
|
15
|
+
"{",
|
|
16
|
+
"\t$0",
|
|
17
|
+
"}"
|
|
18
|
+
],
|
|
19
|
+
description: "Enum"
|
|
20
|
+
};
|
|
21
|
+
var Exception = {
|
|
22
|
+
prefix: "exception",
|
|
23
|
+
body: [
|
|
24
|
+
"[System.Serializable]",
|
|
25
|
+
"public class ${1:My}Exception : ${2:System.Exception}",
|
|
26
|
+
"{",
|
|
27
|
+
"\tpublic ${1:My}Exception() { }",
|
|
28
|
+
"\tpublic ${1:My}Exception(string message) : base(message) { }",
|
|
29
|
+
"\tpublic ${1:My}Exception(string message, System.Exception inner) : base(message, inner) { }",
|
|
30
|
+
"\tprotected ${1:My}Exception(",
|
|
31
|
+
"\t\tSystem.Runtime.Serialization.SerializationInfo info,",
|
|
32
|
+
"\t\tSystem.Runtime.Serialization.StreamingContext context) : base(info, context) { }",
|
|
33
|
+
"}"
|
|
34
|
+
],
|
|
35
|
+
description: "Exception"
|
|
36
|
+
};
|
|
37
|
+
var Indexer = {
|
|
38
|
+
prefix: "indexer",
|
|
39
|
+
body: [
|
|
40
|
+
"${1:public} ${2:object} this[${3:int} index]",
|
|
41
|
+
"{",
|
|
42
|
+
"\tget { $4 }",
|
|
43
|
+
"\tset { $0 }",
|
|
44
|
+
"}"
|
|
45
|
+
],
|
|
46
|
+
description: "Indexer"
|
|
47
|
+
};
|
|
48
|
+
var Interface = {
|
|
49
|
+
prefix: "interface",
|
|
50
|
+
body: [
|
|
51
|
+
"interface I${1:Name}",
|
|
52
|
+
"{",
|
|
53
|
+
"\t$0",
|
|
54
|
+
"}"
|
|
55
|
+
],
|
|
56
|
+
description: "Interface"
|
|
57
|
+
};
|
|
58
|
+
var Namespace = {
|
|
59
|
+
prefix: "namespace",
|
|
60
|
+
body: [
|
|
61
|
+
"namespace ${1:Name}",
|
|
62
|
+
"{",
|
|
63
|
+
"\t$0",
|
|
64
|
+
"}"
|
|
65
|
+
],
|
|
66
|
+
description: "Namespace"
|
|
67
|
+
};
|
|
68
|
+
var FileScopedNamespace = {
|
|
69
|
+
prefix: "fsnamespace",
|
|
70
|
+
body: [
|
|
71
|
+
"namespace ${1:Name};"
|
|
72
|
+
],
|
|
73
|
+
description: "File-scoped namespace"
|
|
74
|
+
};
|
|
75
|
+
var propg = {
|
|
76
|
+
prefix: "propg",
|
|
77
|
+
body: [
|
|
78
|
+
"public ${1:int} ${2:MyProperty} { get; private set; }$0"
|
|
79
|
+
],
|
|
80
|
+
description: "An automatically implemented property with a 'get' accessor and a private 'set' accessor. C# 3.0 or higher"
|
|
81
|
+
};
|
|
82
|
+
var prop = {
|
|
83
|
+
prefix: "prop",
|
|
84
|
+
body: [
|
|
85
|
+
"public ${1:int} ${2:MyProperty} { get; set; }$0"
|
|
86
|
+
],
|
|
87
|
+
description: "An automatically implemented property. C# 3.0 or higher"
|
|
88
|
+
};
|
|
89
|
+
var sim = {
|
|
90
|
+
prefix: "sim",
|
|
91
|
+
body: [
|
|
92
|
+
"static int Main(string[] args)",
|
|
93
|
+
"{",
|
|
94
|
+
"\t$0",
|
|
95
|
+
"\treturn 0;",
|
|
96
|
+
"}"
|
|
97
|
+
],
|
|
98
|
+
description: "int Main()"
|
|
99
|
+
};
|
|
100
|
+
var Struct = {
|
|
101
|
+
prefix: "struct",
|
|
102
|
+
body: [
|
|
103
|
+
"struct ${1:Name}",
|
|
104
|
+
"{",
|
|
105
|
+
"\t$0",
|
|
106
|
+
"}"
|
|
107
|
+
],
|
|
108
|
+
description: "Struct"
|
|
109
|
+
};
|
|
110
|
+
var svm = {
|
|
111
|
+
prefix: "svm",
|
|
112
|
+
body: [
|
|
113
|
+
"static void Main(string[] args)",
|
|
114
|
+
"{",
|
|
115
|
+
"\t$0",
|
|
116
|
+
"}"
|
|
117
|
+
],
|
|
118
|
+
description: "void Main()"
|
|
119
|
+
};
|
|
120
|
+
var constructor = {
|
|
121
|
+
prefix: "ctor",
|
|
122
|
+
body: [
|
|
123
|
+
"${1:public} ${2:$TM_FILENAME_BASE}(${3:Parameters})",
|
|
124
|
+
"{",
|
|
125
|
+
"\t$0",
|
|
126
|
+
"}"
|
|
127
|
+
],
|
|
128
|
+
description: "constructor"
|
|
129
|
+
};
|
|
130
|
+
var csharp = {
|
|
131
|
+
"Attribute using recommended pattern": {
|
|
132
|
+
prefix: "attribute",
|
|
133
|
+
body: [
|
|
134
|
+
"[System.AttributeUsage(System.AttributeTargets.${1:All}, Inherited = ${2:false}, AllowMultiple = ${3:true})]",
|
|
135
|
+
"sealed class ${4:My}Attribute : System.Attribute",
|
|
136
|
+
"{",
|
|
137
|
+
"\t// See the attribute guidelines at",
|
|
138
|
+
"\t// http://go.microsoft.com/fwlink/?LinkId=85236",
|
|
139
|
+
"\treadonly string positionalString;",
|
|
140
|
+
"\t",
|
|
141
|
+
"\t// This is a positional argument",
|
|
142
|
+
"\tpublic ${4:My}Attribute(string positionalString)",
|
|
143
|
+
"\t{",
|
|
144
|
+
"\t\tthis.positionalString = positionalString;",
|
|
145
|
+
"\t\t",
|
|
146
|
+
"\t\t// TODO: Implement code here",
|
|
147
|
+
"\t\t${5:throw new System.NotImplementedException();}",
|
|
148
|
+
"\t}",
|
|
149
|
+
"\t",
|
|
150
|
+
"\tpublic string PositionalString",
|
|
151
|
+
"\t{",
|
|
152
|
+
"\t\tget { return positionalString; }",
|
|
153
|
+
"\t}",
|
|
154
|
+
"\t",
|
|
155
|
+
"\t// This is a named argument",
|
|
156
|
+
"\tpublic int NamedInt { get; set; }",
|
|
157
|
+
"}"
|
|
158
|
+
],
|
|
159
|
+
description: "Attribute using recommended pattern"
|
|
160
|
+
},
|
|
161
|
+
"Disable format": {
|
|
162
|
+
prefix: "disableformat",
|
|
163
|
+
body: [
|
|
164
|
+
"#pragma warning disable format",
|
|
165
|
+
"$0${TM_SELECTED_TEXT}",
|
|
166
|
+
"#pragma warning restore format"
|
|
167
|
+
],
|
|
168
|
+
description: "disable format of dotnet code"
|
|
169
|
+
},
|
|
170
|
+
"Checked block": {
|
|
171
|
+
prefix: "checked",
|
|
172
|
+
body: [
|
|
173
|
+
"checked",
|
|
174
|
+
"{",
|
|
175
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
176
|
+
"}"
|
|
177
|
+
],
|
|
178
|
+
description: "Checked block"
|
|
179
|
+
},
|
|
180
|
+
Class: Class,
|
|
181
|
+
"Console.WriteLine": {
|
|
182
|
+
prefix: "cw",
|
|
183
|
+
body: [
|
|
184
|
+
"System.Console.WriteLine(${TM_SELECTED_TEXT}$0);"
|
|
185
|
+
],
|
|
186
|
+
description: "Console.WriteLine"
|
|
187
|
+
},
|
|
188
|
+
"do...while loop": {
|
|
189
|
+
prefix: "do",
|
|
190
|
+
body: [
|
|
191
|
+
"do",
|
|
192
|
+
"{",
|
|
193
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
194
|
+
"} while (${1:true});"
|
|
195
|
+
],
|
|
196
|
+
description: "do...while loop"
|
|
197
|
+
},
|
|
198
|
+
"Else statement": {
|
|
199
|
+
prefix: "else",
|
|
200
|
+
body: [
|
|
201
|
+
"else",
|
|
202
|
+
"{",
|
|
203
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
204
|
+
"}"
|
|
205
|
+
],
|
|
206
|
+
description: "Else statement"
|
|
207
|
+
},
|
|
208
|
+
Enum: Enum,
|
|
209
|
+
"Implementing Equals() according to guidelines": {
|
|
210
|
+
prefix: "equals",
|
|
211
|
+
body: [
|
|
212
|
+
"// override object.Equals",
|
|
213
|
+
"public override bool Equals(object obj)",
|
|
214
|
+
"{",
|
|
215
|
+
"\t//",
|
|
216
|
+
"\t// See the full list of guidelines at",
|
|
217
|
+
"\t// http://go.microsoft.com/fwlink/?LinkID=85237",
|
|
218
|
+
"\t// and also the guidance for operator== at",
|
|
219
|
+
"\t// http://go.microsoft.com/fwlink/?LinkId=85238",
|
|
220
|
+
"\t//",
|
|
221
|
+
"\t",
|
|
222
|
+
"\tif (obj == null || GetType() != obj.GetType())",
|
|
223
|
+
"\t{",
|
|
224
|
+
"\t\treturn false;",
|
|
225
|
+
"\t}",
|
|
226
|
+
"\t",
|
|
227
|
+
"\t// TODO: write your implementation of Equals() here",
|
|
228
|
+
"\t${1:throw new System.NotImplementedException();}",
|
|
229
|
+
"\treturn base.Equals (obj);",
|
|
230
|
+
"}",
|
|
231
|
+
"",
|
|
232
|
+
"// override object.GetHashCode",
|
|
233
|
+
"public override int GetHashCode()",
|
|
234
|
+
"{",
|
|
235
|
+
"\t// TODO: write your implementation of GetHashCode() here",
|
|
236
|
+
"\t${2:throw new System.NotImplementedException();}",
|
|
237
|
+
"\treturn base.GetHashCode();",
|
|
238
|
+
"}"
|
|
239
|
+
],
|
|
240
|
+
description: "Implementing Equals() according to guidelines"
|
|
241
|
+
},
|
|
242
|
+
Exception: Exception,
|
|
243
|
+
"Foreach statement": {
|
|
244
|
+
prefix: "foreach",
|
|
245
|
+
body: [
|
|
246
|
+
"foreach (${1:var} ${2:item} in ${3:collection})",
|
|
247
|
+
"{",
|
|
248
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
249
|
+
"}"
|
|
250
|
+
],
|
|
251
|
+
description: "Foreach statement"
|
|
252
|
+
},
|
|
253
|
+
"Reverse for loop": {
|
|
254
|
+
prefix: "forr",
|
|
255
|
+
body: [
|
|
256
|
+
"for (int ${1:i} = ${2:length} - 1; ${1:i} >= 0 ; ${1:i}--)",
|
|
257
|
+
"{",
|
|
258
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
259
|
+
"}"
|
|
260
|
+
],
|
|
261
|
+
description: "Reverse for loop"
|
|
262
|
+
},
|
|
263
|
+
"for loop": {
|
|
264
|
+
prefix: "for",
|
|
265
|
+
body: [
|
|
266
|
+
"for (int ${1:i} = 0; ${1:i} < ${2:length}; ${1:i}++)",
|
|
267
|
+
"{",
|
|
268
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
269
|
+
"}"
|
|
270
|
+
],
|
|
271
|
+
description: "for loop"
|
|
272
|
+
},
|
|
273
|
+
"if statement": {
|
|
274
|
+
prefix: "if",
|
|
275
|
+
body: [
|
|
276
|
+
"if (${1:true})",
|
|
277
|
+
"{",
|
|
278
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
279
|
+
"}"
|
|
280
|
+
],
|
|
281
|
+
description: "if statement"
|
|
282
|
+
},
|
|
283
|
+
Indexer: Indexer,
|
|
284
|
+
Interface: Interface,
|
|
285
|
+
"Safely invoking an event": {
|
|
286
|
+
prefix: "invoke",
|
|
287
|
+
body: [
|
|
288
|
+
"${1:EventHandler} temp = ${2:MyEvent};",
|
|
289
|
+
"if (temp != null)",
|
|
290
|
+
"{",
|
|
291
|
+
"\ttemp($0);",
|
|
292
|
+
"}"
|
|
293
|
+
],
|
|
294
|
+
description: "Safely invoking an event"
|
|
295
|
+
},
|
|
296
|
+
"Simple iterator": {
|
|
297
|
+
prefix: "iterator",
|
|
298
|
+
body: [
|
|
299
|
+
"public System.Collections.Generic.IEnumerator<${1:ElementType}> GetEnumerator()",
|
|
300
|
+
"{",
|
|
301
|
+
"\t$0throw new System.NotImplementedException();",
|
|
302
|
+
"\tyield return default(${1:ElementType});",
|
|
303
|
+
"}"
|
|
304
|
+
],
|
|
305
|
+
description: "Simple iterator"
|
|
306
|
+
},
|
|
307
|
+
"Named iterator/indexer pair using a nested class": {
|
|
308
|
+
prefix: "iterindex",
|
|
309
|
+
body: [
|
|
310
|
+
"public ${1:Name}Iterator ${1:Name}",
|
|
311
|
+
"{",
|
|
312
|
+
"\tget",
|
|
313
|
+
"\t{",
|
|
314
|
+
"\t\treturn new ${1:Name}Iterator(this);",
|
|
315
|
+
"\t}",
|
|
316
|
+
"}",
|
|
317
|
+
"",
|
|
318
|
+
"public class ${1:Name}Iterator",
|
|
319
|
+
"{",
|
|
320
|
+
"\treadonly ${2:ClassName} outer;",
|
|
321
|
+
"\t",
|
|
322
|
+
"\tinternal ${1:Name}Iterator(${2:ClassName} outer)",
|
|
323
|
+
"\t{",
|
|
324
|
+
"\t\tthis.outer = outer;",
|
|
325
|
+
"\t}",
|
|
326
|
+
"\t",
|
|
327
|
+
"\t// TODO: provide an appropriate implementation here",
|
|
328
|
+
"\tpublic int Length { get { return 1; } }",
|
|
329
|
+
"\t",
|
|
330
|
+
"\tpublic ${3:ElementType} this[int index]",
|
|
331
|
+
"\t{",
|
|
332
|
+
"\t\tget",
|
|
333
|
+
"\t\t{",
|
|
334
|
+
"\t\t\t//",
|
|
335
|
+
"\t\t\t// TODO: implement indexer here",
|
|
336
|
+
"\t\t\t//",
|
|
337
|
+
"\t\t\t// you have full access to ${2:ClassName} privates",
|
|
338
|
+
"\t\t\t//",
|
|
339
|
+
"\t\t\t${4:throw new System.NotImplementedException();}",
|
|
340
|
+
"\t\t\treturn default(${3:ElementType});",
|
|
341
|
+
"\t\t}",
|
|
342
|
+
"\t}",
|
|
343
|
+
"\t",
|
|
344
|
+
"\tpublic System.Collections.Generic.IEnumerator<${3:ElementType}> GetEnumerator()",
|
|
345
|
+
"\t{",
|
|
346
|
+
"\t\tfor (int i = 0; i < this.Length; i++)",
|
|
347
|
+
"\t\t{",
|
|
348
|
+
"\t\t\tyield return this[i];",
|
|
349
|
+
"\t\t}",
|
|
350
|
+
"\t}",
|
|
351
|
+
"}"
|
|
352
|
+
],
|
|
353
|
+
description: "Named iterator/indexer pair using a nested class"
|
|
354
|
+
},
|
|
355
|
+
"Lock statement": {
|
|
356
|
+
prefix: "lock",
|
|
357
|
+
body: [
|
|
358
|
+
"lock (${1:this})",
|
|
359
|
+
"{",
|
|
360
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
361
|
+
"}"
|
|
362
|
+
],
|
|
363
|
+
description: "Lock statement"
|
|
364
|
+
},
|
|
365
|
+
"MessageBox.Show": {
|
|
366
|
+
prefix: "mbox",
|
|
367
|
+
body: [
|
|
368
|
+
"System.Windows.Forms.MessageBox.Show(\"${1:Text}\");$0"
|
|
369
|
+
],
|
|
370
|
+
description: "MessageBox.Show"
|
|
371
|
+
},
|
|
372
|
+
Namespace: Namespace,
|
|
373
|
+
FileScopedNamespace: FileScopedNamespace,
|
|
374
|
+
"#if": {
|
|
375
|
+
prefix: "ifd",
|
|
376
|
+
body: [
|
|
377
|
+
"#if ${1:true}",
|
|
378
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
379
|
+
"#endif"
|
|
380
|
+
],
|
|
381
|
+
description: "#if"
|
|
382
|
+
},
|
|
383
|
+
"#region": {
|
|
384
|
+
prefix: "region",
|
|
385
|
+
body: [
|
|
386
|
+
"#region ${1:Name}",
|
|
387
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
388
|
+
"#endregion"
|
|
389
|
+
],
|
|
390
|
+
description: "#region"
|
|
391
|
+
},
|
|
392
|
+
"Property and backing field": {
|
|
393
|
+
prefix: "propfull",
|
|
394
|
+
body: [
|
|
395
|
+
"private ${1:int} ${2:myVar};",
|
|
396
|
+
"public ${1:int} ${3:MyProperty}",
|
|
397
|
+
"{",
|
|
398
|
+
"\tget { return ${2:myVar}; }",
|
|
399
|
+
"\tset { ${2:myVar} = value; }",
|
|
400
|
+
"}",
|
|
401
|
+
"$0"
|
|
402
|
+
],
|
|
403
|
+
description: "Property and backing field"
|
|
404
|
+
},
|
|
405
|
+
propg: propg,
|
|
406
|
+
prop: prop,
|
|
407
|
+
sim: sim,
|
|
408
|
+
Struct: Struct,
|
|
409
|
+
svm: svm,
|
|
410
|
+
"Switch statement": {
|
|
411
|
+
prefix: "switch",
|
|
412
|
+
body: [
|
|
413
|
+
"switch (${1:switch_on})",
|
|
414
|
+
"{",
|
|
415
|
+
"\t$0",
|
|
416
|
+
"\tdefault:",
|
|
417
|
+
"}"
|
|
418
|
+
],
|
|
419
|
+
description: "Switch statement"
|
|
420
|
+
},
|
|
421
|
+
"Try finally": {
|
|
422
|
+
prefix: "tryf",
|
|
423
|
+
body: [
|
|
424
|
+
"try",
|
|
425
|
+
"{",
|
|
426
|
+
"\t${TM_SELECTED_TEXT}$1",
|
|
427
|
+
"}",
|
|
428
|
+
"finally",
|
|
429
|
+
"{",
|
|
430
|
+
"\t$0",
|
|
431
|
+
"}"
|
|
432
|
+
],
|
|
433
|
+
description: "Try finally"
|
|
434
|
+
},
|
|
435
|
+
"Try catch": {
|
|
436
|
+
prefix: "try",
|
|
437
|
+
body: [
|
|
438
|
+
"try",
|
|
439
|
+
"{",
|
|
440
|
+
"\t${TM_SELECTED_TEXT}$1",
|
|
441
|
+
"}",
|
|
442
|
+
"catch (${2:System.Exception})",
|
|
443
|
+
"{",
|
|
444
|
+
"\t$0",
|
|
445
|
+
"\tthrow;",
|
|
446
|
+
"}"
|
|
447
|
+
],
|
|
448
|
+
description: "Try catch"
|
|
449
|
+
},
|
|
450
|
+
"Unchecked block": {
|
|
451
|
+
prefix: "unchecked",
|
|
452
|
+
body: [
|
|
453
|
+
"unchecked",
|
|
454
|
+
"{",
|
|
455
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
456
|
+
"}"
|
|
457
|
+
],
|
|
458
|
+
description: "Unchecked block"
|
|
459
|
+
},
|
|
460
|
+
"Unsafe statement": {
|
|
461
|
+
prefix: "unsafe",
|
|
462
|
+
body: [
|
|
463
|
+
"unsafe",
|
|
464
|
+
"{",
|
|
465
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
466
|
+
"}"
|
|
467
|
+
],
|
|
468
|
+
description: "Unsafe statement"
|
|
469
|
+
},
|
|
470
|
+
"Using statement": {
|
|
471
|
+
prefix: "using",
|
|
472
|
+
body: [
|
|
473
|
+
"using (${1:resource})",
|
|
474
|
+
"{",
|
|
475
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
476
|
+
"}"
|
|
477
|
+
],
|
|
478
|
+
description: "Using statement"
|
|
479
|
+
},
|
|
480
|
+
"While loop": {
|
|
481
|
+
prefix: "while",
|
|
482
|
+
body: [
|
|
483
|
+
"while (${1:true})",
|
|
484
|
+
"{",
|
|
485
|
+
"\t${TM_SELECTED_TEXT}$0",
|
|
486
|
+
"}"
|
|
487
|
+
],
|
|
488
|
+
description: "While loop"
|
|
489
|
+
},
|
|
490
|
+
constructor: constructor,
|
|
491
|
+
"xUnit Test": {
|
|
492
|
+
prefix: "fact",
|
|
493
|
+
body: [
|
|
494
|
+
"[Fact]",
|
|
495
|
+
"public void ${1:TestName}()",
|
|
496
|
+
"{",
|
|
497
|
+
"\t// Given",
|
|
498
|
+
"",
|
|
499
|
+
"\t// When",
|
|
500
|
+
"",
|
|
501
|
+
"\t// Then",
|
|
502
|
+
"}$0"
|
|
503
|
+
],
|
|
504
|
+
description: "create xunit test method"
|
|
505
|
+
}
|
|
506
|
+
};
|
|
507
|
+
|
|
508
|
+
export { Class, Enum, Exception, FileScopedNamespace, Indexer, Interface, Namespace, Struct, constructor, csharp as default, prop, propg, sim, svm };
|
package/dist/d2.js
CHANGED
|
@@ -276,7 +276,7 @@ var repository = {
|
|
|
276
276
|
patterns: [
|
|
277
277
|
{
|
|
278
278
|
match: "\\^\\^|\\+\\+|--|(?<!/)\\+(?!/)|-|~|(?<!/)\\*(?!/)|(?<![+*/])/(?![+*/])|%",
|
|
279
|
-
name: "keyword.operator.
|
|
279
|
+
name: "keyword.operator.numeric.d"
|
|
280
280
|
}
|
|
281
281
|
]
|
|
282
282
|
},
|
|
@@ -1375,9 +1375,6 @@ var repository = {
|
|
|
1375
1375
|
},
|
|
1376
1376
|
{
|
|
1377
1377
|
include: "#function-prelude"
|
|
1378
|
-
},
|
|
1379
|
-
{
|
|
1380
|
-
include: "#function-parameters"
|
|
1381
1378
|
}
|
|
1382
1379
|
]
|
|
1383
1380
|
},
|
|
@@ -1389,17 +1386,6 @@ var repository = {
|
|
|
1389
1386
|
}
|
|
1390
1387
|
]
|
|
1391
1388
|
},
|
|
1392
|
-
"function-parameters": {
|
|
1393
|
-
begin: "\\((?=.*\\)\\s*(\\{|=>))",
|
|
1394
|
-
beginCaptures: "entity.name.function.d",
|
|
1395
|
-
end: "\\)",
|
|
1396
|
-
endCaptures: "entity.name.function.d",
|
|
1397
|
-
patterns: [
|
|
1398
|
-
{
|
|
1399
|
-
include: "#parameters"
|
|
1400
|
-
}
|
|
1401
|
-
]
|
|
1402
|
-
},
|
|
1403
1389
|
"class-members": {
|
|
1404
1390
|
patterns: [
|
|
1405
1391
|
{
|
|
@@ -1425,56 +1411,6 @@ var repository = {
|
|
|
1425
1411
|
}
|
|
1426
1412
|
]
|
|
1427
1413
|
},
|
|
1428
|
-
parameters: {
|
|
1429
|
-
patterns: [
|
|
1430
|
-
{
|
|
1431
|
-
match: ",",
|
|
1432
|
-
name: "keyword.operator.comma.d"
|
|
1433
|
-
},
|
|
1434
|
-
{
|
|
1435
|
-
include: "#comment"
|
|
1436
|
-
},
|
|
1437
|
-
{
|
|
1438
|
-
include: "#parameter"
|
|
1439
|
-
}
|
|
1440
|
-
]
|
|
1441
|
-
},
|
|
1442
|
-
parameter: {
|
|
1443
|
-
patterns: [
|
|
1444
|
-
{
|
|
1445
|
-
include: "#in-out"
|
|
1446
|
-
},
|
|
1447
|
-
{
|
|
1448
|
-
include: "#type"
|
|
1449
|
-
},
|
|
1450
|
-
{
|
|
1451
|
-
include: "#function-literal"
|
|
1452
|
-
},
|
|
1453
|
-
{
|
|
1454
|
-
match: "\\.\\.\\.",
|
|
1455
|
-
name: "support.type.tuple.d"
|
|
1456
|
-
},
|
|
1457
|
-
{
|
|
1458
|
-
match: "\\b[R-Z]([0-9])?\\b",
|
|
1459
|
-
name: "variable.parameter.d"
|
|
1460
|
-
},
|
|
1461
|
-
{
|
|
1462
|
-
match: "\\b(\\.?[_\\w][_\\d\\w]*)+\\b",
|
|
1463
|
-
name: "variable.parameter.d"
|
|
1464
|
-
},
|
|
1465
|
-
{
|
|
1466
|
-
include: "#lexical"
|
|
1467
|
-
}
|
|
1468
|
-
]
|
|
1469
|
-
},
|
|
1470
|
-
"in-out": {
|
|
1471
|
-
patterns: [
|
|
1472
|
-
{
|
|
1473
|
-
match: "\\b(auto|final|in|out|lazy|ref|scope)\\b",
|
|
1474
|
-
name: "storage.type.modifier.inout.d"
|
|
1475
|
-
}
|
|
1476
|
-
]
|
|
1477
|
-
},
|
|
1478
1414
|
"function-attribute": {
|
|
1479
1415
|
patterns: [
|
|
1480
1416
|
{
|
|
@@ -1695,7 +1631,7 @@ var repository = {
|
|
|
1695
1631
|
"enum-declaration": {
|
|
1696
1632
|
patterns: [
|
|
1697
1633
|
{
|
|
1698
|
-
begin: "\\b(enum)\\b\\s+",
|
|
1634
|
+
begin: "\\b(enum)\\b\\s+(?=.*[=;])",
|
|
1699
1635
|
end: "([A-Za-z_][\\w_\\d]*)\\s*(?=;|=|\\()(;)?",
|
|
1700
1636
|
beginCaptures: {
|
|
1701
1637
|
"1": {
|