aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/google/protobuf/struct.pb.cc
diff options
context:
space:
mode:
authorGravatar Adam Cozzette <acozzette@google.com>2016-11-22 15:44:54 -0800
committerGravatar Adam Cozzette <acozzette@google.com>2016-11-22 16:23:55 -0800
commitdb35fe735a6522089250a0a0804fb1fd18340666 (patch)
tree7b1532068eeadef058e1b5bf40056cbebfcee727 /src/google/protobuf/struct.pb.cc
parenta7f300d6ffe2fbc6bdd10495efedbe6c86a29f49 (diff)
Add a "u" suffix to tag numbers in generated code
This seems to be necessary to prevent warnings in some compiler configurations, particularly for tag numbers that are too large to fit in a signed 32-bit int.
Diffstat (limited to 'src/google/protobuf/struct.pb.cc')
-rw-r--r--src/google/protobuf/struct.pb.cc22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/google/protobuf/struct.pb.cc b/src/google/protobuf/struct.pb.cc
index 82f5fb28..8bd2f8be 100644
--- a/src/google/protobuf/struct.pb.cc
+++ b/src/google/protobuf/struct.pb.cc
@@ -301,13 +301,13 @@ bool Struct::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.Struct)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127);
+ ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// map<string, .google.protobuf.Value> fields = 1;
case 1: {
- if (tag == 10) {
+ if (tag == 10u) {
DO_(input->IncrementRecursionDepth());
Struct_FieldsEntry::Parser< ::google::protobuf::internal::MapField<
::std::string, ::google::protobuf::Value,
@@ -764,13 +764,13 @@ bool Value::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.Value)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127);
+ ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// .google.protobuf.NullValue null_value = 1;
case 1: {
- if (tag == 8) {
+ if (tag == 8u) {
int value;
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>(
@@ -784,7 +784,7 @@ bool Value::MergePartialFromCodedStream(
// double number_value = 2;
case 2: {
- if (tag == 17) {
+ if (tag == 17u) {
clear_kind();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>(
@@ -798,7 +798,7 @@ bool Value::MergePartialFromCodedStream(
// string string_value = 3;
case 3: {
- if (tag == 26) {
+ if (tag == 26u) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_string_value()));
DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
@@ -813,7 +813,7 @@ bool Value::MergePartialFromCodedStream(
// bool bool_value = 4;
case 4: {
- if (tag == 32) {
+ if (tag == 32u) {
clear_kind();
DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>(
@@ -827,7 +827,7 @@ bool Value::MergePartialFromCodedStream(
// .google.protobuf.Struct struct_value = 5;
case 5: {
- if (tag == 42) {
+ if (tag == 42u) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_struct_value()));
} else {
@@ -838,7 +838,7 @@ bool Value::MergePartialFromCodedStream(
// .google.protobuf.ListValue list_value = 6;
case 6: {
- if (tag == 50) {
+ if (tag == 50u) {
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual(
input, mutable_list_value()));
} else {
@@ -1585,13 +1585,13 @@ bool ListValue::MergePartialFromCodedStream(
::google::protobuf::uint32 tag;
// @@protoc_insertion_point(parse_start:google.protobuf.ListValue)
for (;;) {
- ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127);
+ ::std::pair< ::google::protobuf::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u);
tag = p.first;
if (!p.second) goto handle_unusual;
switch (::google::protobuf::internal::WireFormatLite::GetTagFieldNumber(tag)) {
// repeated .google.protobuf.Value values = 1;
case 1: {
- if (tag == 10) {
+ if (tag == 10u) {
DO_(input->IncrementRecursionDepth());
DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtualNoRecursionDepth(
input, add_values()));