Skip to content

Struct definitions can have repeated fields #7377

Closed
@huonw

Description

@huonw
struct Foo { a: uint, a: uint }

compiles fine.

Constructing a Foo literal doesn't work, listing two as gives field a specified more than once, giving only one a gives error: missing fields:, with an empty list of missing fields.

Metadata

Metadata

Assignees

No one assigned

    Labels

    E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions