diff options
Diffstat (limited to 'src/google/protobuf/compiler/java/java_enum_field.cc')
-rw-r--r-- | src/google/protobuf/compiler/java/java_enum_field.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/google/protobuf/compiler/java/java_enum_field.cc b/src/google/protobuf/compiler/java/java_enum_field.cc index 2e916c56..279b9da4 100644 --- a/src/google/protobuf/compiler/java/java_enum_field.cc +++ b/src/google/protobuf/compiler/java/java_enum_field.cc @@ -58,7 +58,7 @@ void SetEnumVariables(const FieldDescriptor* descriptor, int builderBitIndex, const FieldGeneratorInfo* info, ClassNameResolver* name_resolver, - map<string, string>* variables) { + std::map<string, string>* variables) { SetCommonFieldVariables(descriptor, info, variables); (*variables)["type"] = @@ -68,7 +68,8 @@ void SetEnumVariables(const FieldDescriptor* descriptor, (*variables)["default"] = ImmutableDefaultValue(descriptor, name_resolver); (*variables)["default_number"] = SimpleItoa( descriptor->default_value_enum()->number()); - (*variables)["tag"] = SimpleItoa(internal::WireFormat::MakeTag(descriptor)); + (*variables)["tag"] = + SimpleItoa(static_cast<int32>(internal::WireFormat::MakeTag(descriptor))); (*variables)["tag_size"] = SimpleItoa( internal::WireFormat::TagSize(descriptor->number(), GetType(descriptor))); // TODO(birdo): Add @deprecated javadoc when generating javadoc is supported |