Skip to content
This repository was archived by the owner on Sep 24, 2020. It is now read-only.

The Online Converter messes up object initializers #514

@beppe9000

Description

@beppe9000

When converting C# to Vb.Net using the Online Converter i found two issues, #513 is the first, and this is the second.

Code with object initializers like this

StudentName student2 = new StudentName
        {
            FirstName = "Craig",
            LastName = "Playstead",
        };

is wrongly translated to this (notice the "Key " parts)

Dim student2 As New StudentName() With { _
    Key .FirstName = "Craig", _
    Key .LastName = "Playstead" _
}

instead of this

Dim student2 As New StudentName() With { _
    .FirstName = "Craig", _
    .LastName = "Playstead" _
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions