Status: New
Owner: liuj...@google.com
Labels: Type-Defect Priority-Medium

New issue 313 by agca...@gmail.com: in c++ generated header, has_FIELD will return random results if more than 32 optional fields defined in single message
http://code.google.com/p/protobuf/issues/detail?id=313

What steps will reproduce the problem?
1. Define a message with more than 32 optional fields and compile to c++ header 2. write function that execute has_FIELD() where FIELD is the name of the field it an id greater that 32 3. depending on where you land in the 32 bit has_bits_ variable it may return true even though there is no data in the field.

What is the expected output? What do you see instead?

it should not be random, but give the correct answer.

What version of the product are you using? On what operating system?

2.4.1

Please provide any additional information below.

either don't allow more than 32 optional fields, use unlimited bit field construct to allow unlimited optional fields.

Compiler should not allow this if 32 is the max.

--
You received this message because you are subscribed to the Google Groups "Protocol 
Buffers" group.
To post to this group, send email to protobuf@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