{ "fileTypes": [ "vb" ], "name": "VB.NET", "patterns": [ { "include": "#singleLineComment" }, { "include": "#region" }, { "include": "#quotedString" }, { "include": "#compilerOption" }, { "include": "#importDefinition" }, { "include": "#numericConstant" }, { "include": "#characterOperator" }, { "include": "#lineContinuationOperator" }, { "include": "#wordOperator" }, { "include": "#languageContants" }, { "include": "#compilerDirectives" }, { "include": "#supportTypes" }, { "include": "#suportFunctions" }, { "include": "#linqKeywords" }, { "include": "#languageVariable" }, { "include": "#namespaceDefinition" }, { "include": "#moduleDefinition" }, { "include": "#interfaceDefinition" }, { "include": "#classDefinition" }, { "include": "#functionDefinition" }, { "include": "#lambdaDefinition" }, { "include": "#propertyDefinition" }, { "include": "#propertyGetSet" }, { "include": "#definitionEnd" }, { "include": "#storageModifiers" }, { "include": "#inheritanceModifiers" }, { "include": "#controlKeywords" }, { "include": "#modifierKeywords" }, { "include": "#vbFunctions" } ], "repository": { "characterOperator": { "match": "(\\.|\\+=|\\+|\\*=|\\*|\\\\=|\\\\|/=|/|=|-=|-|<|<=|>|>=|&=|&|\\^|\\^=|>>=|>>|<<=|<<|:=)", "name": "keyword.operator.vbnet" }, "classDefinition": { "captures": { "1": { "name": "storage.type.class.vbnet" }, "2": { "name": "entity.name.type.class.vbnet" } }, "match": "(?i:\\b(class)\\s+([a-zA-Z_]\\w*)\\s*)", "name": "meta.class.vbnet" }, "compilerDirectives": { "match": "^\\s*(?i:#if|#else|#elseif|#endif|#const|#externalsource|#end|#end externalsource)\\s+", "name": "keyword.directive.vbnet" }, "compilerOption": { "captures": { "1": { "name": "keyword.other.compiler-option.vbnet" }, "2": { "name": "support.constant.compiler-option.vbnet" }, "3": { "name": "constant.language.option-value.vbnet" } }, "match": "(?i:^\\s*(option)\\s*(strict|infer|explicit|compare)\\s*(on|off|binary|text))" }, "controlKeywords": { "match": "(?i:\\b(If|Then|Else|ElseIf|Else If|End If|While|End While|For|End For|To|Each|Case|Select|End Select|Return|Continue|Do|Until|Loop|Next|End With|With|Exit Do|Exit For|Exit Function|Exit Property|Exit Sub|IIf|Step|GoTo|Try|Catch|Finally|End Try|Using|RaiseEvent|Stop|On Error|Resume|Async|Await|Yield)\\b)", "name": "keyword.control.vbnet" }, "definitionEnd": { "match": "(?i:^\\s*(end)\\s+(function|sub|class|namespace|module|interface|property|addhandler|enum|event|operator|raiseevent|removehandler|select|structure|synclock))", "name": "keyword.control.end-definition.vbnet" }, "functionDefinition": { "begin": "(?i:\\b(function|sub)\\s+([a-zA-Z_]\\w*)\\s*(\\()?)", "beginCaptures": { "1": { "name": "support.type.function.vbnet" }, "2": { "name": "entity.name.function.vbnet" }, "3": { "name": "meta.parameters.vbnet" }, "4": { "name": "punctuation.definition.parameters.vbnet" } }, "end": "(\\))?\\s*", "endCaptures": { "1": { "name": "punctuation.definition.parameters.vbnet" } }, "name": "meta.function.vbnet", "patterns": [ { "include": "#modifierKeywords" }, { "include": "#supportTypes" } ] }, "importDefinition": { "captures": { "1": { "name": "keyword.other.vbnet" }, "2": { "name": "variable.other.namespace-alias.vbnet" } }, "match": "(?i:^\\s*(imports)\\s*([a-zA-Z_]\\w*\\s*=)?\\s*([a-zA-Z_]\\w*\\.?)+)" }, "inheritanceModifiers": { "match": "(?i:overloads|overrides|overridable|notoverridable|mustoverride|mustoverride overrides|notoverridable overrides|overloads overrides|mustinherit|notinheritable)", "name": "storage.modifier.inheritance.vbnet" }, "interfaceDefinition": { "captures": { "1": { "name": "storage.type.interface.vbnet" }, "2": { "name": "entity.name.type.interface.vbnet" } }, "match": "(?i:\\b(interface)\\s+([a-zA-Z_]\\w*)\\s*)", "name": "meta.interface.vbnet" }, "lambdaDefinition": { "match": "(?i:function|sub)", "name": "support.type.lambda.vbnet" }, "languageContants": { "match": "((?i:true|false|nothing))", "name": "constant.language.vbnet" }, "languageVariable": { "match": "\\b((?i:Me|MyBase|MyClass))\\.", "name": "keyword.other.vbnet" }, "lineContinuationOperator": { "match": "\\w*\\b(\\_)$", "name": "keyword.operator.vbnet" }, "linqKeywords": { "match": "(?i:\\b(from|aggregate|select|where|order by|join|groupp by|into|group join|equals|let|distinct|skip|skip while|take|take while)\\b)", "name": "keyword.control.linq.vbnet" }, "modifierKeywords": { "match": "\\b(?i:As|byval|byref|optional|handles|inherits|implements|withevents|end set|end get|of|alias|declare|widening|narrowing|ansi|assembly|auto|iterator|key|unicode)\\s+", "name": "keyword.modifier.vbnet" }, "moduleDefinition": { "captures": { "1": { "name": "storage.type.module.vbnet" }, "2": { "name": "entity.name.type.module.vbnet" } }, "match": "(?i:\\b(module)\\s+([a-zA-Z_]\\w*)\\s*)", "name": "meta.module.vbnet" }, "namespaceDefinition": { "captures": { "1": { "name": "storage.type.namespace.vbnet" }, "2": { "name": "entity.name.type.namespace.vbnet" } }, "match": "\\b((?i:namespace))\\s+([a-zA-Z_]\\w*)\\s*", "name": "meta.namespace.vbnet" }, "numericConstant": { "match": "\\b(-?\\d+(\\.?\\d?)*)", "name": "constant.numeric.vbnet" }, "propertyDefinition": { "begin": "(?i:\\b(property)\\s+([a-zA-Z_]\\w*)\\s*(\\()?)", "beginCaptures": { "1": { "name": "storage.type.property.vbnet" }, "2": { "name": "entity.name.type.property.vbnet" }, "3": { "name": "punctuation.definition.parameters.property.vbnet" } }, "end": "(\\))?\\s*", "endCaptures": { "1": { "name": "punctuation.definition.parameters.property.vbnet" } }, "name": "meta.property.vbnet", "patterns": [ { "include": "#modifierKeywords" }, { "include": "#supportTypes" } ] }, "propertyGetSet": { "match": "(?i:^\\s*(protected friend|protected|friend|private)?\\s+(get|set)\\s*\\(?\\b)", "name": "keyword.other.property.accessor.vbnet" }, "quotedString": { "match": "(\")([^\"]|\"\")*(\")", "name": "string.quoted.double.vbnet" }, "region": { "begin": "^\\s*((?i:#region))", "beginCaptures": { "1": { "name": "keyword.directive.vbnet" } }, "end": "^\\s*((?i:#end region))", "endCaptures": { "1": { "name": "keyword.directive.vbnet" } }, "name": "meta.region.source.vbnet", "patterns": [ { "include": "$self" } ] }, "singleLineComment": { "comment": "single quote comment", "match": "'.*$", "name": "comment.line.singlequote.vbnet" }, "storageModifiers": { "match": "\\b(?i:dim|public|private|protected friend|protected|friend|shadows|static|shared|readonly|default|partial|readonly|writeonly|erase|redim|lib)\\b", "name": "storage.modifier.access.vbnet" }, "suportFunctions": { "match": "(?i:\\b(new|addressof|addhandler|removehandler|throw|typeof|like|call|synclock)\\b)", "name": "support.function.vbnet" }, "supportTypes": { "match": "(?i:\\b(integer|decimal|double|single|date|long|short|char|string|byte|date|boolean|delegate|event|enum|sbyte|uinteger|ulong|ushort|const|object|global|paramarray)\\b)", "name": "support.type.vbnet" }, "vbFunctions": { "captures": { "1": { "name": "support.function.vbnet" } }, "match": "\\b((?i:CBool|CByte|CChar|CDate|CDbl|CDec|Char|CInt|CLng|CObj|CSByte|CShort|CSng|CStr|CType|CUInt|CULng|CUShort|DirectCast|GetType|TryCast|GetXmlNamespace))\\(" }, "wordOperator": { "match": "(?i:\\b(mod|not|and|andalso|or|orelse|in|is|isnot|xor|out)\\b)", "name": "keyword.operator.vbnet" } }, "scopeName": "source.vbnet", "uuid": "975d5447-0eb5-444c-a471-5934193ca1ea" }