aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/protobuf/util/simple_reflection.h
diff options
context:
space:
mode:
authorbotay <botay@yandex-team.ru>2022-02-10 16:50:00 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:50:00 +0300
commitbdd495d3600d61815512f5dc4c1c02f65f047a16 (patch)
tree7c4a950805539954ff6ad9cfb914d9dbeb3f2cfb /library/cpp/protobuf/util/simple_reflection.h
parent32ad1de867d9ab2dd9dc78caae239ab3a524110b (diff)
downloadydb-bdd495d3600d61815512f5dc4c1c02f65f047a16.tar.gz
Restoring authorship annotation for <botay@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/protobuf/util/simple_reflection.h')
-rw-r--r--library/cpp/protobuf/util/simple_reflection.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/library/cpp/protobuf/util/simple_reflection.h b/library/cpp/protobuf/util/simple_reflection.h
index 61e877a787..fe470c53a8 100644
--- a/library/cpp/protobuf/util/simple_reflection.h
+++ b/library/cpp/protobuf/util/simple_reflection.h
@@ -103,7 +103,7 @@ namespace NProtoBuf {
const Reflection& Refl() const {
return *Msg.GetReflection();
}
-
+
[[noreturn]] void RaiseUnknown() const {
ythrow yexception() << "Unknown field cpp-type: " << (size_t)CppType();
}
@@ -127,7 +127,7 @@ namespace NProtoBuf {
static TMaybe<TMutableField> ByPath(Message& msg, const TStringBuf& path, bool createPath = false);
static TMaybe<TMutableField> ByPath(Message& msg, const TVector<const FieldDescriptor*>& fieldsPath, bool createPath = false);
static TMaybe<TMutableField> ByPath(Message& msg, const TFieldPath& fieldsPath, bool createPath = false);
-
+
Message* MutableParent() {
return Mut();
}
@@ -187,7 +187,7 @@ namespace NProtoBuf {
Y_ASSERT(index == 0);
return Refl().MutableMessage(Mut(), Fd);
}
- }
+ }
template <typename TMsg>
inline TMsg* AddMessage() {
@@ -203,7 +203,7 @@ namespace NProtoBuf {
Message* Mut() {
return const_cast<Message*>(&Msg);
}
-
+
template <typename T>
inline void MergeValue(T srcValue);
};
@@ -255,8 +255,8 @@ namespace NProtoBuf {
template <typename T>
inline void TMutableField::MergeValue(T srcValue) {
- Add(srcValue);
- }
+ Add(srcValue);
+ }
template <>
inline void TMutableField::MergeValue<const Message*>(const Message* srcValue) {
@@ -264,8 +264,8 @@ namespace NProtoBuf {
Add(srcValue);
} else {
MutableMessage()->MergeFrom(*srcValue);
- }
- }
+ }
+ }
inline void TMutableField::MergeFrom(const TConstField& src) {
Y_ASSERT(HasSameType(src));
@@ -286,4 +286,4 @@ namespace NProtoBuf {
#undef TMP_MACRO_FOR_CPPTYPE
}
-}
+}