From 2726632054376ac374c068336b85d868299570f9 Mon Sep 17 00:00:00 2001 From: Mike Kruskal Date: Wed, 6 Dec 2023 20:07:18 -0800 Subject: [PATCH] Internal changes PiperOrigin-RevId: 588627840 --- src/google/protobuf/descriptor.cc | 1 + src/google/protobuf/descriptor_unittest.cc | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/google/protobuf/descriptor.cc b/src/google/protobuf/descriptor.cc index 4690c3d5c8..ce37423c94 100644 --- a/src/google/protobuf/descriptor.cc +++ b/src/google/protobuf/descriptor.cc @@ -3125,6 +3125,7 @@ bool FormatLineOptions(int depth, const Message& options, return !all_options.empty(); } + class SourceLocationCommentPrinter { public: template diff --git a/src/google/protobuf/descriptor_unittest.cc b/src/google/protobuf/descriptor_unittest.cc index 244f5c54ee..843b181143 100644 --- a/src/google/protobuf/descriptor_unittest.cc +++ b/src/google/protobuf/descriptor_unittest.cc @@ -14,6 +14,7 @@ #include "google/protobuf/descriptor.h" #include +#include #include #include #include @@ -4018,7 +4019,7 @@ class ValidationErrorTest : public testing::Test { } // Parse file_text as a FileDescriptorProto in text format and add it // to the DescriptorPool. Expect no errors. - const FileDescriptor* BuildFile(const std::string& file_text) { + const FileDescriptor* BuildFile(absl::string_view file_text) { FileDescriptorProto file_proto; EXPECT_TRUE(TextFormat::ParseFromString(file_text, &file_proto)); return ABSL_DIE_IF_NULL(pool_.BuildFile(file_proto)); @@ -10496,6 +10497,7 @@ TEST_F(DescriptorPoolFeaturesTest, OverrideDefaults) { + TEST_F(ValidationErrorTest, ExtensionDeclarationsMatchFullNameCompile) { BuildFile(R"pb( name: "foo.proto"