(d'oh; replied to wrong address...)
I'm fairly sure that 3 is correct; if it was 3, then 3 bits of
field_number would be lost, and the next 3 would overlap with wire_type.
I did notice an error in the language document though - a missing semicolon
relating to imports, IIRC...
Marc
2009/8/28
Yup, actually I got it wrong
(field_number 3) | wire_type represents how to encode/generate Key
and not how to decode it...
in the next line it has been written as right-shift field
number.. which makes things clear
Sorry again for the mess up...
Varun
On Aug
Note that field number means the number you assign to the field in the
.proto file, whereas tag means the bytes that come before the field value
in the encoded message. You left-shift the field number to make the tag,
and right-shift the tag to get the field number.
On Fri, Aug 28, 2009 at 12:28