diff options
author | Daniil Cherednik <dan.cherednik@gmail.com> | 2022-09-21 20:17:38 +0300 |
---|---|---|
committer | Daniil Cherednik <dan.cherednik@gmail.com> | 2022-09-21 20:17:38 +0300 |
commit | e6c9b17192c56494adba359d5e132c431b241191 (patch) | |
tree | 6f2449871a118a0e8919ce842b1174e06cb470ef /library/cpp/protobuf | |
parent | 285021ab1aac39e84b269d9bacd4deee69cf63fc (diff) | |
download | ydb-22.4.21.tar.gz |
Ydb stable 22-4-2122.4.21
x-stable-origin-commit: e89099581237299a132feafb5b58af59ebd0468a
Diffstat (limited to 'library/cpp/protobuf')
-rw-r--r-- | library/cpp/protobuf/CMakeLists.txt | 11 | ||||
-rw-r--r-- | library/cpp/protobuf/json/json2proto.cpp | 3 | ||||
-rw-r--r-- | library/cpp/protobuf/util/CMakeLists.txt | 1 |
3 files changed, 13 insertions, 2 deletions
diff --git a/library/cpp/protobuf/CMakeLists.txt b/library/cpp/protobuf/CMakeLists.txt new file mode 100644 index 0000000000..41b18218f1 --- /dev/null +++ b/library/cpp/protobuf/CMakeLists.txt @@ -0,0 +1,11 @@ + +# This file was gererated by the build system used internally in the Yandex monorepo. +# Only simple modifications are allowed (adding source-files to targets, adding simple properties +# like target_include_directories). These modifications will be ported to original +# ya.make files by maintainers. Any complex modifications which can't be ported back to the +# original buildsystem will not be accepted. + + +add_subdirectory(interop) +add_subdirectory(json) +add_subdirectory(util) diff --git a/library/cpp/protobuf/json/json2proto.cpp b/library/cpp/protobuf/json/json2proto.cpp index 640c10f5a5..92bfe9755b 100644 --- a/library/cpp/protobuf/json/json2proto.cpp +++ b/library/cpp/protobuf/json/json2proto.cpp @@ -377,10 +377,9 @@ namespace NProtobufJson { return; } - Y_ENSURE(json.IsMap(), "expected json map"); - const google::protobuf::Descriptor* descriptor = proto.GetDescriptor(); Y_ASSERT(!!descriptor); + Y_ENSURE(json.IsMap(), "Failed to merge json to proto for message: " << descriptor->full_name() << ", expected json map."); for (int f = 0, endF = descriptor->field_count(); f < endF; ++f) { const google::protobuf::FieldDescriptor* field = descriptor->field(f); diff --git a/library/cpp/protobuf/util/CMakeLists.txt b/library/cpp/protobuf/util/CMakeLists.txt index d25187fbdb..d04f95d395 100644 --- a/library/cpp/protobuf/util/CMakeLists.txt +++ b/library/cpp/protobuf/util/CMakeLists.txt @@ -6,6 +6,7 @@ # original buildsystem will not be accepted. +add_subdirectory(proto) add_library(cpp-protobuf-util) target_link_libraries(cpp-protobuf-util PUBLIC |