Don't copy SpecificField data in MessageDifferencer unnecessarily.

PiperOrigin-RevId: 694010705
pull/19154/head
Protobuf Team Bot 3 months ago committed by Copybara-Service
parent 707c747650
commit 7c3eb4155f
  1. 17
      csharp/src/Google.Protobuf/Reflection/FeatureSetDescriptor.g.cs
  2. 2
      src/google/protobuf/util/message_differencer.cc

@ -1,17 +0,0 @@
#region Copyright notice and license
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
//
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file or at
// https://developers.google.com/open-source/licenses/bsd
#endregion
namespace Google.Protobuf.Reflection;
internal sealed partial class FeatureSetDescriptor
{
// Canonical serialized form of the edition defaults, generated by embed_edition_defaults.
private const string DefaultsBase64 =
"ChMYhAciACoMCAEQAhgCIAMoATACChMY5wciACoMCAIQARgBIAIoATABChMY6AciDAgBEAEYASACKAEwASoAIOYHKOgH";
}

@ -2111,7 +2111,7 @@ MessageDifferencer::StreamReporter::~StreamReporter() {
void MessageDifferencer::StreamReporter::PrintPath(
const std::vector<SpecificField>& field_path, bool left_side) {
for (size_t i = 0; i < field_path.size(); ++i) {
SpecificField specific_field = field_path[i];
const SpecificField& specific_field = field_path[i];
if (specific_field.field != nullptr &&
specific_field.field->name() == "value") {

Loading…
Cancel
Save