diff options
author | Chris Kennelly <ckennelly@google.com> | 2017-01-31 13:10:13 -0800 |
---|---|---|
committer | Chris Kennelly <ckennelly@google.com> | 2017-02-15 11:35:24 -0800 |
commit | 0026dff9f6e7fbea541fd293cbf8ebcd254e374d (patch) | |
tree | 56c1af9b7e1ca9da51a61bdcf97e18a50d4252f3 /src/google/protobuf/type.pb.cc | |
parent | 38b14408c5f58737cfa3a5433ef319e90e891702 (diff) | |
download | protobuf-0026dff9f6e7fbea541fd293cbf8ebcd254e374d.tar.gz protobuf-0026dff9f6e7fbea541fd293cbf8ebcd254e374d.tar.bz2 protobuf-0026dff9f6e7fbea541fd293cbf8ebcd254e374d.zip |
Expose rvalue setters for repeated string fields.
rvalue setters for scalar string fields were added in #2506.
Diffstat (limited to 'src/google/protobuf/type.pb.cc')
-rw-r--r-- | src/google/protobuf/type.pb.cc | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/google/protobuf/type.pb.cc b/src/google/protobuf/type.pb.cc index 50d7be43..36d5ba40 100644 --- a/src/google/protobuf/type.pb.cc +++ b/src/google/protobuf/type.pb.cc @@ -957,6 +957,12 @@ void Type::set_oneofs(int index, const ::std::string& value) { // @@protoc_insertion_point(field_set:google.protobuf.Type.oneofs) oneofs_.Mutable(index)->assign(value); } +#if LANG_CXX11 +void Type::set_oneofs(int index, ::std::string&& value) { + // @@protoc_insertion_point(field_set:google.protobuf.Type.oneofs) + oneofs_.Mutable(index)->assign(std::move(value)); +} +#endif void Type::set_oneofs(int index, const char* value) { oneofs_.Mutable(index)->assign(value); // @@protoc_insertion_point(field_set_char:google.protobuf.Type.oneofs) @@ -974,6 +980,12 @@ void Type::add_oneofs(const ::std::string& value) { oneofs_.Add()->assign(value); // @@protoc_insertion_point(field_add:google.protobuf.Type.oneofs) } +#if LANG_CXX11 +void Type::add_oneofs(::std::string&& value) { + oneofs_.Add()->assign(std::move(value)); + // @@protoc_insertion_point(field_add:google.protobuf.Type.oneofs) +} +#endif void Type::add_oneofs(const char* value) { oneofs_.Add()->assign(value); // @@protoc_insertion_point(field_add_char:google.protobuf.Type.oneofs) |