Skip to content

Produce compile-time error on (required) set on an Empty field #146

@alexander-yevsyukov

Description

@alexander-yevsyukov

Such an option set on a field with the type google.protobuf.Empty should not compile because enclosing message could not be built using the generated validation code.

When checking for a filled in value, we compare the value with a default instance of a message, and the result would be always true.

This also should include implicitly required field such as IDs for command messages or entity states.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions