Re: [protobuf] Tags and values

2018-01-22 Thread 'Feng Xiao' via Protocol Buffers
On Mon, Jan 22, 2018 at 3:08 PM, Ashwin Kini wrote: > Hi all, > > While defining messages can the *tags *be non continous? The > documentation never mentions the same > > message abc { > optional uint32 xyz = *100*; > optional uint32 def = *200*; > optional unit32 abc =

Re: [protobuf] Tags and values

2018-01-22 Thread Marc Gravell
Yes, tags (field numbers) can be non-contiguous. Yes, hex is accepted by protoc No, repeated fields cannot be required On 22 January 2018 at 23:08, Ashwin Kini wrote: > Hi all, > > While defining messages can the *tags *be non continous? The > documentation never

[protobuf] Tags and values

2018-01-22 Thread Ashwin Kini
Hi all, While defining messages can the *tags *be non continous? The documentation never mentions the same message abc { optional uint32 xyz = *100*; optional uint32 def = *200*; optional unit32 abc = *0xDEAD01*; } The documentation says it needs to be unique. Agreed. Can they be non