Commit 403d216d authored by Thomas BARBIER's avatar Thomas BARBIER

Fix error: unused parameter 'arena' and 'default_value' [-Werror=unused-parameter]

parent 4e308267
...@@ -67,27 +67,27 @@ class PROTOBUF_EXPORT InlinedStringField { ...@@ -67,27 +67,27 @@ class PROTOBUF_EXPORT InlinedStringField {
const InlinedStringField& from) PROTOBUF_ALWAYS_INLINE; const InlinedStringField& from) PROTOBUF_ALWAYS_INLINE;
void ClearToEmpty(const ::std::string* default_value, void ClearToEmpty(const ::std::string* default_value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
ClearToEmptyNoArena(default_value); ClearToEmptyNoArena(default_value);
} }
void ClearNonDefaultToEmpty() PROTOBUF_ALWAYS_INLINE { void ClearNonDefaultToEmpty() PROTOBUF_ALWAYS_INLINE {
ClearNonDefaultToEmptyNoArena(); ClearNonDefaultToEmptyNoArena();
} }
void ClearToEmptyNoArena(const ::std::string* default_value) void ClearToEmptyNoArena(const ::std::string* /*default_value*/)
PROTOBUF_ALWAYS_INLINE { PROTOBUF_ALWAYS_INLINE {
ClearNonDefaultToEmptyNoArena(); ClearNonDefaultToEmptyNoArena();
} }
void ClearNonDefaultToEmptyNoArena() PROTOBUF_ALWAYS_INLINE; void ClearNonDefaultToEmptyNoArena() PROTOBUF_ALWAYS_INLINE;
void ClearToDefault(const ::std::string* default_value, void ClearToDefault(const ::std::string* default_value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
ClearToDefaultNoArena(default_value); ClearToDefaultNoArena(default_value);
} }
void ClearToDefaultNoArena(const ::std::string* default_value) void ClearToDefaultNoArena(const ::std::string* default_value)
PROTOBUF_ALWAYS_INLINE; PROTOBUF_ALWAYS_INLINE;
void Destroy(const ::std::string* default_value, void Destroy(const ::std::string* default_value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
DestroyNoArena(default_value); DestroyNoArena(default_value);
} }
void DestroyNoArena(const ::std::string* default_value) PROTOBUF_ALWAYS_INLINE; void DestroyNoArena(const ::std::string* default_value) PROTOBUF_ALWAYS_INLINE;
...@@ -96,16 +96,16 @@ class PROTOBUF_EXPORT InlinedStringField { ...@@ -96,16 +96,16 @@ class PROTOBUF_EXPORT InlinedStringField {
const ::std::string& GetNoArena() const PROTOBUF_ALWAYS_INLINE; const ::std::string& GetNoArena() const PROTOBUF_ALWAYS_INLINE;
::std::string* Mutable(const ::std::string* default_value, ::std::string* Mutable(const ::std::string* default_value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
return MutableNoArena(default_value); return MutableNoArena(default_value);
} }
::std::string* MutableNoArena(const ::std::string* default_value) ::std::string* MutableNoArena(const ::std::string* default_value)
PROTOBUF_ALWAYS_INLINE; PROTOBUF_ALWAYS_INLINE;
::std::string* Release(const ::std::string* default_value, Arena* arena) { ::std::string* Release(const ::std::string* default_value, Arena* /*arena*/) {
return ReleaseNoArena(default_value); return ReleaseNoArena(default_value);
} }
::std::string* ReleaseNonDefault(const ::std::string* default_value, Arena* arena) { ::std::string* ReleaseNonDefault(const ::std::string* default_value, Arena* /*arena*/) {
return ReleaseNonDefaultNoArena(default_value); return ReleaseNonDefaultNoArena(default_value);
} }
::std::string* ReleaseNoArena(const ::std::string* default_value) { ::std::string* ReleaseNoArena(const ::std::string* default_value) {
...@@ -114,22 +114,22 @@ class PROTOBUF_EXPORT InlinedStringField { ...@@ -114,22 +114,22 @@ class PROTOBUF_EXPORT InlinedStringField {
::std::string* ReleaseNonDefaultNoArena(const ::std::string* default_value); ::std::string* ReleaseNonDefaultNoArena(const ::std::string* default_value);
void Set(const ::std::string* default_value, StringPiece value, void Set(const ::std::string* default_value, StringPiece value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
SetNoArena(default_value, value); SetNoArena(default_value, value);
} }
void SetLite(const ::std::string* default_value, StringPiece value, void SetLite(const ::std::string* default_value, StringPiece value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
SetNoArena(default_value, value); SetNoArena(default_value, value);
} }
void SetNoArena(const ::std::string* default_value, void SetNoArena(const ::std::string* default_value,
StringPiece value) PROTOBUF_ALWAYS_INLINE; StringPiece value) PROTOBUF_ALWAYS_INLINE;
void Set(const ::std::string* default_value, const ::std::string& value, void Set(const ::std::string* default_value, const ::std::string& value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
SetNoArena(default_value, value); SetNoArena(default_value, value);
} }
void SetLite(const ::std::string* default_value, const ::std::string& value, void SetLite(const ::std::string* default_value, const ::std::string& value,
Arena* arena) PROTOBUF_ALWAYS_INLINE { Arena* /*arena*/) PROTOBUF_ALWAYS_INLINE {
SetNoArena(default_value, value); SetNoArena(default_value, value);
} }
void SetNoArena(const ::std::string* default_value, void SetNoArena(const ::std::string* default_value,
...@@ -141,7 +141,7 @@ class PROTOBUF_EXPORT InlinedStringField { ...@@ -141,7 +141,7 @@ class PROTOBUF_EXPORT InlinedStringField {
#endif #endif
void SetAllocated(const ::std::string* default_value, void SetAllocated(const ::std::string* default_value,
::std::string* value, ::std::string* value,
Arena* arena) { Arena* /*arena*/) {
SetAllocatedNoArena(default_value, value); SetAllocatedNoArena(default_value, value);
} }
void SetAllocatedNoArena(const ::std::string* default_value, void SetAllocatedNoArena(const ::std::string* default_value,
...@@ -153,7 +153,7 @@ class PROTOBUF_EXPORT InlinedStringField { ...@@ -153,7 +153,7 @@ class PROTOBUF_EXPORT InlinedStringField {
void UnsafeArenaSetAllocated( void UnsafeArenaSetAllocated(
const ::std::string* default_value, ::std::string* value, Arena* arena); const ::std::string* default_value, ::std::string* value, Arena* arena);
bool IsDefault(const ::std::string* default_value) { bool IsDefault(const ::std::string* /*default_value*/) {
return false; return false;
} }
private: private:
...@@ -166,7 +166,7 @@ inline InlinedStringField::InlinedStringField(const ::std::string& default_value ...@@ -166,7 +166,7 @@ inline InlinedStringField::InlinedStringField(const ::std::string& default_value
value_(default_value) {} value_(default_value) {}
inline void InlinedStringField::AssignWithDefault( inline void InlinedStringField::AssignWithDefault(
const ::std::string* default_value, const InlinedStringField& from) { const ::std::string* /*default_value*/, const InlinedStringField& from) {
value_ = from.value_; value_ = from.value_;
} }
...@@ -214,19 +214,19 @@ inline ::std::string* InlinedStringField::ReleaseNonDefaultNoArena( ...@@ -214,19 +214,19 @@ inline ::std::string* InlinedStringField::ReleaseNonDefaultNoArena(
return released; return released;
} }
inline void InlinedStringField::SetNoArena(const ::std::string* default_value, inline void InlinedStringField::SetNoArena(const ::std::string* /*default_value*/,
StringPiece value) { StringPiece value) {
value_.assign(value.data(), value.length()); value_.assign(value.data(), value.length());
} }
inline void InlinedStringField::SetNoArena( inline void InlinedStringField::SetNoArena(
const ::std::string* default_value, const ::std::string& value) { const ::std::string* /*default_value*/, const ::std::string& value) {
value_.assign(value); value_.assign(value);
} }
#if LANG_CXX11 #if LANG_CXX11
inline void InlinedStringField::SetNoArena( inline void InlinedStringField::SetNoArena(
const ::std::string* default_value, ::std::string&& value) { const ::std::string* /*default_value*/, ::std::string&& value) {
value_.assign(std::move(value)); value_.assign(std::move(value));
} }
#endif #endif
...@@ -245,12 +245,12 @@ inline void InlinedStringField::UnsafeSetDefault( ...@@ -245,12 +245,12 @@ inline void InlinedStringField::UnsafeSetDefault(
} }
inline ::std::string* InlinedStringField::UnsafeArenaRelease( inline ::std::string* InlinedStringField::UnsafeArenaRelease(
const ::std::string* default_value, Arena* arena) { const ::std::string* default_value, Arena* /*arena*/) {
return ReleaseNoArena(default_value); return ReleaseNoArena(default_value);
} }
inline void InlinedStringField::UnsafeArenaSetAllocated( inline void InlinedStringField::UnsafeArenaSetAllocated(
const ::std::string* default_value, ::std::string* value, Arena* arena) { const ::std::string* default_value, ::std::string* value, Arena* /*arena*/) {
if (value == NULL) { if (value == NULL) {
value_.assign(*default_value); value_.assign(*default_value);
} else { } else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment