aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFeng Xiao <xfxyjwf@gmail.com>2018-06-11 14:37:05 -0700
committerGitHub <noreply@github.com>2018-06-11 14:37:05 -0700
commitf81a3910c07daba7d1f2fd57e328692fc8c480ca (patch)
tree7ba8a4a263018d17fd7ae45a071c86fb47f244b1
parent35c6927cc13aceef90fe5dba7eceae28bde50045 (diff)
parent9de458ab964c524169cd87cdc520c2ad20212b2d (diff)
downloadprotobuf-f81a3910c07daba7d1f2fd57e328692fc8c480ca.tar.gz
protobuf-f81a3910c07daba7d1f2fd57e328692fc8c480ca.tar.bz2
protobuf-f81a3910c07daba7d1f2fd57e328692fc8c480ca.zip
Merge pull request #3901 from wijagels/master
Fix unused parameter warnings in generated code with arenas enabled
-rw-r--r--src/google/protobuf/compiler/cpp/cpp_message.cc2
-rw-r--r--src/google/protobuf/descriptor.pb.cc54
2 files changed, 28 insertions, 28 deletions
diff --git a/src/google/protobuf/compiler/cpp/cpp_message.cc b/src/google/protobuf/compiler/cpp/cpp_message.cc
index 8c2336af..778fc406 100644
--- a/src/google/protobuf/compiler/cpp/cpp_message.cc
+++ b/src/google/protobuf/compiler/cpp/cpp_message.cc
@@ -2280,7 +2280,7 @@ GenerateArenaDestructorCode(io::Printer* printer) {
"classname", classname_);
} else {
printer->Print(
- "void $classname$::RegisterArenaDtor(::google::protobuf::Arena* arena) {\n"
+ "void $classname$::RegisterArenaDtor(::google::protobuf::Arena*) {\n"
"}\n",
"classname", classname_);
}
diff --git a/src/google/protobuf/descriptor.pb.cc b/src/google/protobuf/descriptor.pb.cc
index 59b04aba..348f5d95 100644
--- a/src/google/protobuf/descriptor.pb.cc
+++ b/src/google/protobuf/descriptor.pb.cc
@@ -1487,7 +1487,7 @@ void FileDescriptorSet::ArenaDtor(void* object) {
FileDescriptorSet* _this = reinterpret_cast< FileDescriptorSet* >(object);
(void)_this;
}
-void FileDescriptorSet::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void FileDescriptorSet::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void FileDescriptorSet::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -1840,7 +1840,7 @@ void FileDescriptorProto::ArenaDtor(void* object) {
FileDescriptorProto* _this = reinterpret_cast< FileDescriptorProto* >(object);
(void)_this;
}
-void FileDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void FileDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void FileDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -2642,7 +2642,7 @@ void DescriptorProto_ExtensionRange::ArenaDtor(void* object) {
DescriptorProto_ExtensionRange* _this = reinterpret_cast< DescriptorProto_ExtensionRange* >(object);
(void)_this;
}
-void DescriptorProto_ExtensionRange::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void DescriptorProto_ExtensionRange::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void DescriptorProto_ExtensionRange::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -2994,7 +2994,7 @@ void DescriptorProto_ReservedRange::ArenaDtor(void* object) {
DescriptorProto_ReservedRange* _this = reinterpret_cast< DescriptorProto_ReservedRange* >(object);
(void)_this;
}
-void DescriptorProto_ReservedRange::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void DescriptorProto_ReservedRange::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void DescriptorProto_ReservedRange::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -3350,7 +3350,7 @@ void DescriptorProto::ArenaDtor(void* object) {
DescriptorProto* _this = reinterpret_cast< DescriptorProto* >(object);
(void)_this;
}
-void DescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void DescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void DescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -4032,7 +4032,7 @@ void ExtensionRangeOptions::ArenaDtor(void* object) {
ExtensionRangeOptions* _this = reinterpret_cast< ExtensionRangeOptions* >(object);
(void)_this;
}
-void ExtensionRangeOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void ExtensionRangeOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void ExtensionRangeOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -4390,7 +4390,7 @@ void FieldDescriptorProto::ArenaDtor(void* object) {
FieldDescriptorProto* _this = reinterpret_cast< FieldDescriptorProto* >(object);
(void)_this;
}
-void FieldDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void FieldDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void FieldDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -5120,7 +5120,7 @@ void OneofDescriptorProto::ArenaDtor(void* object) {
OneofDescriptorProto* _this = reinterpret_cast< OneofDescriptorProto* >(object);
(void)_this;
}
-void OneofDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void OneofDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void OneofDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -5450,7 +5450,7 @@ void EnumDescriptorProto_EnumReservedRange::ArenaDtor(void* object) {
EnumDescriptorProto_EnumReservedRange* _this = reinterpret_cast< EnumDescriptorProto_EnumReservedRange* >(object);
(void)_this;
}
-void EnumDescriptorProto_EnumReservedRange::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void EnumDescriptorProto_EnumReservedRange::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void EnumDescriptorProto_EnumReservedRange::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -5791,7 +5791,7 @@ void EnumDescriptorProto::ArenaDtor(void* object) {
EnumDescriptorProto* _this = reinterpret_cast< EnumDescriptorProto* >(object);
(void)_this;
}
-void EnumDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void EnumDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void EnumDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -6283,7 +6283,7 @@ void EnumValueDescriptorProto::ArenaDtor(void* object) {
EnumValueDescriptorProto* _this = reinterpret_cast< EnumValueDescriptorProto* >(object);
(void)_this;
}
-void EnumValueDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void EnumValueDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void EnumValueDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -6676,7 +6676,7 @@ void ServiceDescriptorProto::ArenaDtor(void* object) {
ServiceDescriptorProto* _this = reinterpret_cast< ServiceDescriptorProto* >(object);
(void)_this;
}
-void ServiceDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void ServiceDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void ServiceDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -7096,7 +7096,7 @@ void MethodDescriptorProto::ArenaDtor(void* object) {
MethodDescriptorProto* _this = reinterpret_cast< MethodDescriptorProto* >(object);
(void)_this;
}
-void MethodDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void MethodDescriptorProto::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void MethodDescriptorProto::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -7694,7 +7694,7 @@ void FileOptions::ArenaDtor(void* object) {
FileOptions* _this = reinterpret_cast< FileOptions* >(object);
(void)_this;
}
-void FileOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void FileOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void FileOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -8885,7 +8885,7 @@ void MessageOptions::ArenaDtor(void* object) {
MessageOptions* _this = reinterpret_cast< MessageOptions* >(object);
(void)_this;
}
-void MessageOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void MessageOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void MessageOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -9329,7 +9329,7 @@ void FieldOptions::ArenaDtor(void* object) {
FieldOptions* _this = reinterpret_cast< FieldOptions* >(object);
(void)_this;
}
-void FieldOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void FieldOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void FieldOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -9848,7 +9848,7 @@ void OneofOptions::ArenaDtor(void* object) {
OneofOptions* _this = reinterpret_cast< OneofOptions* >(object);
(void)_this;
}
-void OneofOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void OneofOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void OneofOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -10145,7 +10145,7 @@ void EnumOptions::ArenaDtor(void* object) {
EnumOptions* _this = reinterpret_cast< EnumOptions* >(object);
(void)_this;
}
-void EnumOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void EnumOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void EnumOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -10514,7 +10514,7 @@ void EnumValueOptions::ArenaDtor(void* object) {
EnumValueOptions* _this = reinterpret_cast< EnumValueOptions* >(object);
(void)_this;
}
-void EnumValueOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void EnumValueOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void EnumValueOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -10842,7 +10842,7 @@ void ServiceOptions::ArenaDtor(void* object) {
ServiceOptions* _this = reinterpret_cast< ServiceOptions* >(object);
(void)_this;
}
-void ServiceOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void ServiceOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void ServiceOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -11175,7 +11175,7 @@ void MethodOptions::ArenaDtor(void* object) {
MethodOptions* _this = reinterpret_cast< MethodOptions* >(object);
(void)_this;
}
-void MethodOptions::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void MethodOptions::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void MethodOptions::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -11559,7 +11559,7 @@ void UninterpretedOption_NamePart::ArenaDtor(void* object) {
UninterpretedOption_NamePart* _this = reinterpret_cast< UninterpretedOption_NamePart* >(object);
(void)_this;
}
-void UninterpretedOption_NamePart::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void UninterpretedOption_NamePart::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void UninterpretedOption_NamePart::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -11924,7 +11924,7 @@ void UninterpretedOption::ArenaDtor(void* object) {
UninterpretedOption* _this = reinterpret_cast< UninterpretedOption* >(object);
(void)_this;
}
-void UninterpretedOption::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void UninterpretedOption::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void UninterpretedOption::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -12473,7 +12473,7 @@ void SourceCodeInfo_Location::ArenaDtor(void* object) {
SourceCodeInfo_Location* _this = reinterpret_cast< SourceCodeInfo_Location* >(object);
(void)_this;
}
-void SourceCodeInfo_Location::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void SourceCodeInfo_Location::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void SourceCodeInfo_Location::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -12979,7 +12979,7 @@ void SourceCodeInfo::ArenaDtor(void* object) {
SourceCodeInfo* _this = reinterpret_cast< SourceCodeInfo* >(object);
(void)_this;
}
-void SourceCodeInfo::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void SourceCodeInfo::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void SourceCodeInfo::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -13258,7 +13258,7 @@ void GeneratedCodeInfo_Annotation::ArenaDtor(void* object) {
GeneratedCodeInfo_Annotation* _this = reinterpret_cast< GeneratedCodeInfo_Annotation* >(object);
(void)_this;
}
-void GeneratedCodeInfo_Annotation::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void GeneratedCodeInfo_Annotation::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void GeneratedCodeInfo_Annotation::SetCachedSize(int size) const {
_cached_size_.Set(size);
@@ -13676,7 +13676,7 @@ void GeneratedCodeInfo::ArenaDtor(void* object) {
GeneratedCodeInfo* _this = reinterpret_cast< GeneratedCodeInfo* >(object);
(void)_this;
}
-void GeneratedCodeInfo::RegisterArenaDtor(::google::protobuf::Arena* arena) {
+void GeneratedCodeInfo::RegisterArenaDtor(::google::protobuf::Arena*) {
}
void GeneratedCodeInfo::SetCachedSize(int size) const {
_cached_size_.Set(size);