On Thu, Jan 7, 2010 at 1:35 PM, Graham Cox <cox.gra...@gmail.com> wrote:

> On 7 Jan 2010, at 21:14, Kenton Varda <ken...@google.com> wrote:
>
>> Use the wrapper message technique combined with extensions:
>>
>
> One thing to be careful with this method is not double-allocating extension
> numbers, or does the compiler take" care of that for you?"
>

The compiler will detect duplicate extension numbers if it sees them, but
that requires that you compile them with the same invocation of protoc.
 Duplicate extension numbers will also be caught at program start-up in C++
and Python, or by ExtensionRegistry in Java.  But there's nothing to stop
two separate programs from defining the same extension number if neither one
compiles in the other one's definition.  So yes, you do need to be careful.
--
You received this message because you are subscribed to the Google Groups "Protocol Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to protobuf+unsubscr...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/protobuf?hl=en.

Reply via email to