There are also few warnings I don't know how to handle properly
protobuf-2.4.1\src\google\protobuf\text_format.cc:126: warning: C4355: 'this' : used in base member initializer list protobuf-2.4.1\src\google\protobuf\compiler\importer.cc:118: warning: C4355: 'this' : used in base member initializer list
protobuf-2.4.1\src\google\protobuf\text_format.cc:423: warning: C4800: 'google::protobuf::uint64' : forcing value to bool 'true' or 'false' (performance warning) protobuf-2.4.1\src\google\protobuf\text_format.cc:423: warning: C4800: 'google::protobuf::uint64' : forcing value to bool 'true' or 'false' (performance warning) protobuf-2.4.1\src\google\protobuf\generated_message_reflection.cc:1149: warning: C4800: 'const google::protobuf::uint32' : forcing value to bool 'true' or 'false' (performance warning)
In my setup, at least, GCC doesn't complain about "forcing value to bool", or about "'this' : used in base member initializer list".
I frankly think the "forcing value to bool" is a bogus error that should be suppressed in everyone's project. I honestly don't believe there is any significant "performance" penalty at all - the last time I looked at the generated code for bool a = x; and bool a = (x != 0); they were exactly the same.
The unit test warning probably should be suppressed with a pragma BUT if it isn't bothering people within Google IMHO this is a much lower priority.
As an external developer who makes heavy use of protocol buffers, I only ever ran the Google unit tests one time, and I really didn't care if there were a few warnings there. But warnings in my main build are troublesome because I like to have none at all so I can clearly see "real" warnings when they come up.
It's the convention at Google to use "int" as loop counters, which makes it
pointless to update the code to use "size_t" as it's inevitable that new
code will introduce more "int"s in the future.
Unless Google's style guide discourages the use of "int", we shouldn't
bother to make the change.