|Did you know ...||Search Documentation:|
The protobuf grammar provides a reserved word,
that indicates that the production rule that it refers to may appear
once or not at all in a protobuf message. Since Prolog has its own means
of alternation, this reserved word is not supported on the Prolog side.
It is anticipated that customary Prolog mechanisms for nondeterminism
(e.g. backtracking) will be used to generate and test alternatives.
optional have been
removed from the proto3 specification, making all fields optional. This
has been partially revised in releases 3.12 and later. In general, you
should not expect any field to exist, nor can you expect a repeated
field to have at least one item.
Also note that the handling of missing fields is slightly different in proto2 and proto3 -- proto2 allows specifying a default value but proto3 uses 0 and =""= as defaults for numbers and strings and omits encoding any field that has one of those default values.