VB arrange fails on code with From and With keywords / initializers
Status: Beta
Brought to you by:
jamesnies
The VB arrange sub-project does not handle the With and From keywords. It throws a parsing exception upon reaching the '.varname'.
The language functionality for From/With was added in .NET 9.0
Example code:
Public Shared descriptor as DescriptorProto = New DescriptorProto() With {
.name = "FileDescriptorSet", '<- fails here'
.field = New List(of FieldDescriptorProto)() From {
New FieldDescriptorProto() With {
.name = "file",
.number = 1,
.label = FieldDescriptorProto.Nested.Label.LABEL_REPEATED,
.type = FieldDescriptorProto.Nested.Type.TYPE_MESSAGE,
.type_name = ".google.protobuf.FileDescriptorProto",
.fieldInfo = GetType(FileDescriptorSet).GetField("file")}},
.extension = New List(of FieldDescriptorProto)() From {
},
.nested_type = New List(of DescriptorProto)(0),
.enum_type = New List(of EnumDescriptorProto)(0),
.extension_range = New List(of DescriptorProto.Nested.ExtensionRange)() From {
},
.constructor = New DescriptorProto.ConstructorDelegate(Function() New FileDescriptorSet())}