Skip to content

Forward usage of nested enums generates ruby files that can't be loaded #48

@sergiocampama

Description

@sergiocampama

Repro: https://github.com/sergiocampama/ruby_proto_repro, just run generate_proto.sh from inside the repo.

What happens is that the MessageB gets added to the forward declaration, but its internal enums are not, so the subsequent usage of the enum type fails to be resolved.

One way to fix this particular would be to forward declare all enums, even nested ones, before messages. Then forward declare the messages and finally then extend the messages with any fields that they have defined.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions