diff options
Diffstat (limited to 'csharp/src/Google.Protobuf.Test/TestProtos')
8 files changed, 1692 insertions, 508 deletions
diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/MapUnittestProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/MapUnittestProto3.cs index 9c0518a3..cb1bc920 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/MapUnittestProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/MapUnittestProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/map_unittest_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: map_unittest_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -9,11 +11,11 @@ using pbr = global::Google.Protobuf.Reflection; using scg = global::System.Collections.Generic; namespace Google.Protobuf.TestProtos { - /// <summary>Holder for reflection information generated from google/protobuf/map_unittest_proto3.proto</summary> + /// <summary>Holder for reflection information generated from map_unittest_proto3.proto</summary> public static partial class MapUnittestProto3Reflection { #region Descriptor - /// <summary>File descriptor for google/protobuf/map_unittest_proto3.proto</summary> + /// <summary>File descriptor for map_unittest_proto3.proto</summary> public static pbr::FileDescriptor Descriptor { get { return descriptor; } } @@ -22,130 +24,130 @@ namespace Google.Protobuf.TestProtos { static MapUnittestProto3Reflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "Cilnb29nbGUvcHJvdG9idWYvbWFwX3VuaXR0ZXN0X3Byb3RvMy5wcm90bxIR", - "cHJvdG9idWZfdW5pdHRlc3QaJWdvb2dsZS9wcm90b2J1Zi91bml0dGVzdF9w", - "cm90bzMucHJvdG8ilhIKB1Rlc3RNYXASRgoPbWFwX2ludDMyX2ludDMyGAEg", - "AygLMi0ucHJvdG9idWZfdW5pdHRlc3QuVGVzdE1hcC5NYXBJbnQzMkludDMy", - "RW50cnkSRgoPbWFwX2ludDY0X2ludDY0GAIgAygLMi0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KCFRZUEVfRk9P", + "EAAingEKH01lc3NhZ2VDb250YWluaW5nTWFwQ2FsbGVkRW50cnkSTQoFZW50", + "cnkYASADKAsyPi5wcm90b2J1Zl91bml0dGVzdDMuTWVzc2FnZUNvbnRhaW5p", + "bmdNYXBDYWxsZWRFbnRyeS5FbnRyeUVudHJ5GiwKCkVudHJ5RW50cnkSCwoD", + "a2V5GAEgASgFEg0KBXZhbHVlGAIgASgFOgI4ASo/CgdNYXBFbnVtEhAKDE1B", + "UF9FTlVNX0ZPTxAAEhAKDE1BUF9FTlVNX0JBUhABEhAKDE1BUF9FTlVNX0JB", + "WhACQh2qAhpHb29nbGUuUHJvdG9idWYuVGVzdFByb3Rvc2IGcHJvdG8z")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Google.Protobuf.TestProtos.UnittestProto3Reflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Google.Protobuf.TestProtos.MapEnum), }, new pbr::GeneratedClrTypeInfo[] { @@ -176,6 +178,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestMap : pb::IMessage<TestMap> { private static readonly pb::MessageParser<TestMap> _parser = new pb::MessageParser<TestMap>(() => new TestMap()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMap> Parser { get { return _parser; } } @@ -215,6 +218,7 @@ namespace Google.Protobuf.TestProtos { mapInt32Bytes_ = other.mapInt32Bytes_.Clone(); mapInt32Enum_ = other.mapInt32Enum_.Clone(); mapInt32ForeignMessage_ = other.mapInt32ForeignMessage_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -422,7 +426,7 @@ namespace Google.Protobuf.TestProtos { if (!MapInt32Bytes.Equals(other.MapInt32Bytes)) return false; if (!MapInt32Enum.Equals(other.MapInt32Enum)) return false; if (!MapInt32ForeignMessage.Equals(other.MapInt32ForeignMessage)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -445,6 +449,9 @@ namespace Google.Protobuf.TestProtos { hash ^= MapInt32Bytes.GetHashCode(); hash ^= MapInt32Enum.GetHashCode(); hash ^= MapInt32ForeignMessage.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -472,6 +479,9 @@ namespace Google.Protobuf.TestProtos { mapInt32Bytes_.WriteTo(output, _map_mapInt32Bytes_codec); mapInt32Enum_.WriteTo(output, _map_mapInt32Enum_codec); mapInt32ForeignMessage_.WriteTo(output, _map_mapInt32ForeignMessage_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -494,6 +504,9 @@ namespace Google.Protobuf.TestProtos { size += mapInt32Bytes_.CalculateSize(_map_mapInt32Bytes_codec); size += mapInt32Enum_.CalculateSize(_map_mapInt32Enum_codec); size += mapInt32ForeignMessage_.CalculateSize(_map_mapInt32ForeignMessage_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -519,6 +532,7 @@ namespace Google.Protobuf.TestProtos { mapInt32Bytes_.Add(other.mapInt32Bytes_); mapInt32Enum_.Add(other.mapInt32Enum_); mapInt32ForeignMessage_.Add(other.mapInt32ForeignMessage_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -527,7 +541,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { mapInt32Int32_.AddEntriesFrom(input, _map_mapInt32Int32_codec); @@ -605,6 +619,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestMapSubmessage : pb::IMessage<TestMapSubmessage> { private static readonly pb::MessageParser<TestMapSubmessage> _parser = new pb::MessageParser<TestMapSubmessage>(() => new TestMapSubmessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMapSubmessage> Parser { get { return _parser; } } @@ -628,6 +643,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestMapSubmessage(TestMapSubmessage other) : this() { TestMap = other.testMap_ != null ? other.TestMap.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -660,13 +676,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!object.Equals(TestMap, other.TestMap)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (testMap_ != null) hash ^= TestMap.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -681,6 +700,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteMessage(TestMap); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -689,6 +711,9 @@ namespace Google.Protobuf.TestProtos { if (testMap_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(TestMap); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -703,6 +728,7 @@ namespace Google.Protobuf.TestProtos { } TestMap.MergeFrom(other.TestMap); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -711,7 +737,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (testMap_ == null) { @@ -728,6 +754,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestMessageMap : pb::IMessage<TestMessageMap> { private static readonly pb::MessageParser<TestMessageMap> _parser = new pb::MessageParser<TestMessageMap>(() => new TestMessageMap()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMessageMap> Parser { get { return _parser; } } @@ -751,6 +778,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestMessageMap(TestMessageMap other) : this() { mapInt32Message_ = other.mapInt32Message_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -782,13 +810,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!MapInt32Message.Equals(other.MapInt32Message)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= MapInt32Message.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -800,12 +831,18 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { mapInt32Message_.WriteTo(output, _map_mapInt32Message_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += mapInt32Message_.CalculateSize(_map_mapInt32Message_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -815,6 +852,7 @@ namespace Google.Protobuf.TestProtos { return; } mapInt32Message_.Add(other.mapInt32Message_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -823,7 +861,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { mapInt32Message_.AddEntriesFrom(input, _map_mapInt32Message_codec); @@ -840,6 +878,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestSameTypeMap : pb::IMessage<TestSameTypeMap> { private static readonly pb::MessageParser<TestSameTypeMap> _parser = new pb::MessageParser<TestSameTypeMap>(() => new TestSameTypeMap()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestSameTypeMap> Parser { get { return _parser; } } @@ -864,6 +903,7 @@ namespace Google.Protobuf.TestProtos { public TestSameTypeMap(TestSameTypeMap other) : this() { map1_ = other.map1_.Clone(); map2_ = other.map2_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -906,7 +946,7 @@ namespace Google.Protobuf.TestProtos { } if (!Map1.Equals(other.Map1)) return false; if (!Map2.Equals(other.Map2)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -914,6 +954,9 @@ namespace Google.Protobuf.TestProtos { int hash = 1; hash ^= Map1.GetHashCode(); hash ^= Map2.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -926,6 +969,9 @@ namespace Google.Protobuf.TestProtos { public void WriteTo(pb::CodedOutputStream output) { map1_.WriteTo(output, _map_map1_codec); map2_.WriteTo(output, _map_map2_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -933,6 +979,9 @@ namespace Google.Protobuf.TestProtos { int size = 0; size += map1_.CalculateSize(_map_map1_codec); size += map2_.CalculateSize(_map_map2_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -943,6 +992,7 @@ namespace Google.Protobuf.TestProtos { } map1_.Add(other.map1_); map2_.Add(other.map2_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -951,7 +1001,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { map1_.AddEntriesFrom(input, _map_map1_codec); @@ -969,6 +1019,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestArenaMap : pb::IMessage<TestArenaMap> { private static readonly pb::MessageParser<TestArenaMap> _parser = new pb::MessageParser<TestArenaMap>(() => new TestArenaMap()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestArenaMap> Parser { get { return _parser; } } @@ -1006,6 +1057,7 @@ namespace Google.Protobuf.TestProtos { mapBoolBool_ = other.mapBoolBool_.Clone(); mapInt32Enum_ = other.mapInt32Enum_.Clone(); mapInt32ForeignMessage_ = other.mapInt32ForeignMessage_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1191,7 +1243,7 @@ namespace Google.Protobuf.TestProtos { if (!MapBoolBool.Equals(other.MapBoolBool)) return false; if (!MapInt32Enum.Equals(other.MapInt32Enum)) return false; if (!MapInt32ForeignMessage.Equals(other.MapInt32ForeignMessage)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1212,6 +1264,9 @@ namespace Google.Protobuf.TestProtos { hash ^= MapBoolBool.GetHashCode(); hash ^= MapInt32Enum.GetHashCode(); hash ^= MapInt32ForeignMessage.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1237,6 +1292,9 @@ namespace Google.Protobuf.TestProtos { mapBoolBool_.WriteTo(output, _map_mapBoolBool_codec); mapInt32Enum_.WriteTo(output, _map_mapInt32Enum_codec); mapInt32ForeignMessage_.WriteTo(output, _map_mapInt32ForeignMessage_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1257,6 +1315,9 @@ namespace Google.Protobuf.TestProtos { size += mapBoolBool_.CalculateSize(_map_mapBoolBool_codec); size += mapInt32Enum_.CalculateSize(_map_mapInt32Enum_codec); size += mapInt32ForeignMessage_.CalculateSize(_map_mapInt32ForeignMessage_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1280,6 +1341,7 @@ namespace Google.Protobuf.TestProtos { mapBoolBool_.Add(other.mapBoolBool_); mapInt32Enum_.Add(other.mapInt32Enum_); mapInt32ForeignMessage_.Add(other.mapInt32ForeignMessage_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1288,7 +1350,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { mapInt32Int32_.AddEntriesFrom(input, _map_mapInt32Int32_codec); @@ -1362,6 +1424,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class MessageContainingEnumCalledType : pb::IMessage<MessageContainingEnumCalledType> { private static readonly pb::MessageParser<MessageContainingEnumCalledType> _parser = new pb::MessageParser<MessageContainingEnumCalledType>(() => new MessageContainingEnumCalledType()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<MessageContainingEnumCalledType> Parser { get { return _parser; } } @@ -1385,6 +1448,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public MessageContainingEnumCalledType(MessageContainingEnumCalledType other) : this() { type_ = other.type_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1416,13 +1480,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!Type.Equals(other.Type)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= Type.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1434,12 +1501,18 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { type_.WriteTo(output, _map_type_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += type_.CalculateSize(_map_type_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1449,6 +1522,7 @@ namespace Google.Protobuf.TestProtos { return; } type_.Add(other.type_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1457,7 +1531,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { type_.AddEntriesFrom(input, _map_type_codec); @@ -1485,6 +1559,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class MessageContainingMapCalledEntry : pb::IMessage<MessageContainingMapCalledEntry> { private static readonly pb::MessageParser<MessageContainingMapCalledEntry> _parser = new pb::MessageParser<MessageContainingMapCalledEntry>(() => new MessageContainingMapCalledEntry()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<MessageContainingMapCalledEntry> Parser { get { return _parser; } } @@ -1508,6 +1583,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public MessageContainingMapCalledEntry(MessageContainingMapCalledEntry other) : this() { entry_ = other.entry_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1539,13 +1615,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!Entry.Equals(other.Entry)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= Entry.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1557,12 +1636,18 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { entry_.WriteTo(output, _map_entry_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += entry_.CalculateSize(_map_entry_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1572,6 +1657,7 @@ namespace Google.Protobuf.TestProtos { return; } entry_.Add(other.entry_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1580,7 +1666,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { entry_.AddEntriesFrom(input, _map_entry_codec); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/TestMessagesProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/TestMessagesProto3.cs index 6607be7a..a2a236d9 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/TestMessagesProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/TestMessagesProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/test_messages_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/test_messages_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -27,7 +29,7 @@ namespace ProtobufTestMessages.Proto3 { "dWYvYW55LnByb3RvGh5nb29nbGUvcHJvdG9idWYvZHVyYXRpb24ucHJvdG8a", "IGdvb2dsZS9wcm90b2J1Zi9maWVsZF9tYXNrLnByb3RvGhxnb29nbGUvcHJv", "dG9idWYvc3RydWN0LnByb3RvGh9nb29nbGUvcHJvdG9idWYvdGltZXN0YW1w", - "LnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8irDsKElRl", + "LnByb3RvGh5nb29nbGUvcHJvdG9idWYvd3JhcHBlcnMucHJvdG8itDsKElRl", "c3RBbGxUeXBlc1Byb3RvMxIWCg5vcHRpb25hbF9pbnQzMhgBIAEoBRIWCg5v", "cHRpb25hbF9pbnQ2NBgCIAEoAxIXCg9vcHRpb25hbF91aW50MzIYAyABKA0S", "FwoPb3B0aW9uYWxfdWludDY0GAQgASgEEhcKD29wdGlvbmFsX3NpbnQzMhgF", @@ -196,11 +198,11 @@ namespace ProtobufTestMessages.Proto3 { "Z0ZvcmVpZ25FbnVtRW50cnkSCwoDa2V5GAEgASgJEjkKBXZhbHVlGAIgASgO", "MioucHJvdG9idWZfdGVzdF9tZXNzYWdlcy5wcm90bzMuRm9yZWlnbkVudW06", "AjgBIjkKCk5lc3RlZEVudW0SBwoDRk9PEAASBwoDQkFSEAESBwoDQkFaEAIS", - "EAoDTkVHEP///////////wFCDQoLb25lb2ZfZmllbGQiGwoORm9yZWlnbk1l", - "c3NhZ2USCQoBYxgBIAEoBSpACgtGb3JlaWduRW51bRIPCgtGT1JFSUdOX0ZP", - "TxAAEg8KC0ZPUkVJR05fQkFSEAESDwoLRk9SRUlHTl9CQVoQAkI4Cihjb20u", - "Z29vZ2xlLnByb3RvYnVmX3Rlc3RfbWVzc2FnZXMucHJvdG8zSAH4AQGiAgZQ", - "cm90bzNiBnByb3RvMw==")); + "EAoDTkVHEP///////////wFCDQoLb25lb2ZfZmllbGRKBgj1AxD/AyIbCg5G", + "b3JlaWduTWVzc2FnZRIJCgFjGAEgASgFKkAKC0ZvcmVpZ25FbnVtEg8KC0ZP", + "UkVJR05fRk9PEAASDwoLRk9SRUlHTl9CQVIQARIPCgtGT1JFSUdOX0JBWhAC", + "QjgKKGNvbS5nb29nbGUucHJvdG9idWZfdGVzdF9tZXNzYWdlcy5wcm90bzNI", + "AfgBAaICBlByb3RvM2IGcHJvdG8z")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Google.Protobuf.WellKnownTypes.AnyReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.DurationReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.FieldMaskReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.StructReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.TimestampReflection.Descriptor, global::Google.Protobuf.WellKnownTypes.WrappersReflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::ProtobufTestMessages.Proto3.ForeignEnum), }, new pbr::GeneratedClrTypeInfo[] { @@ -233,6 +235,7 @@ namespace ProtobufTestMessages.Proto3 { /// </summary> public sealed partial class TestAllTypesProto3 : pb::IMessage<TestAllTypesProto3> { private static readonly pb::MessageParser<TestAllTypesProto3> _parser = new pb::MessageParser<TestAllTypesProto3>(() => new TestAllTypesProto3()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestAllTypesProto3> Parser { get { return _parser; } } @@ -395,6 +398,7 @@ namespace ProtobufTestMessages.Proto3 { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1730,8 +1734,8 @@ namespace ProtobufTestMessages.Proto3 { if (OptionalFixed64 != other.OptionalFixed64) return false; if (OptionalSfixed32 != other.OptionalSfixed32) return false; if (OptionalSfixed64 != other.OptionalSfixed64) return false; - if (OptionalFloat != other.OptionalFloat) return false; - if (OptionalDouble != other.OptionalDouble) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(OptionalFloat, other.OptionalFloat)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.Equals(OptionalDouble, other.OptionalDouble)) return false; if (OptionalBool != other.OptionalBool) return false; if (OptionalString != other.OptionalString) return false; if (OptionalBytes != other.OptionalBytes) return false; @@ -1788,16 +1792,16 @@ namespace ProtobufTestMessages.Proto3 { if (OneofBytes != other.OneofBytes) return false; if (OneofBool != other.OneofBool) return false; if (OneofUint64 != other.OneofUint64) return false; - if (OneofFloat != other.OneofFloat) return false; - if (OneofDouble != other.OneofDouble) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(OneofFloat, other.OneofFloat)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.Equals(OneofDouble, other.OneofDouble)) return false; if (OneofEnum != other.OneofEnum) return false; if (OptionalBoolWrapper != other.OptionalBoolWrapper) return false; if (OptionalInt32Wrapper != other.OptionalInt32Wrapper) return false; if (OptionalInt64Wrapper != other.OptionalInt64Wrapper) return false; if (OptionalUint32Wrapper != other.OptionalUint32Wrapper) return false; if (OptionalUint64Wrapper != other.OptionalUint64Wrapper) return false; - if (OptionalFloatWrapper != other.OptionalFloatWrapper) return false; - if (OptionalDoubleWrapper != other.OptionalDoubleWrapper) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.Equals(OptionalFloatWrapper, other.OptionalFloatWrapper)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(OptionalDoubleWrapper, other.OptionalDoubleWrapper)) return false; if (OptionalStringWrapper != other.OptionalStringWrapper) return false; if (OptionalBytesWrapper != other.OptionalBytesWrapper) return false; if(!repeatedBoolWrapper_.Equals(other.repeatedBoolWrapper_)) return false; @@ -1840,7 +1844,7 @@ namespace ProtobufTestMessages.Proto3 { if (FieldName17 != other.FieldName17) return false; if (FieldName18 != other.FieldName18) return false; if (OneofFieldCase != other.OneofFieldCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1856,8 +1860,8 @@ namespace ProtobufTestMessages.Proto3 { if (OptionalFixed64 != 0UL) hash ^= OptionalFixed64.GetHashCode(); if (OptionalSfixed32 != 0) hash ^= OptionalSfixed32.GetHashCode(); if (OptionalSfixed64 != 0L) hash ^= OptionalSfixed64.GetHashCode(); - if (OptionalFloat != 0F) hash ^= OptionalFloat.GetHashCode(); - if (OptionalDouble != 0D) hash ^= OptionalDouble.GetHashCode(); + if (OptionalFloat != 0F) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(OptionalFloat); + if (OptionalDouble != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(OptionalDouble); if (OptionalBool != false) hash ^= OptionalBool.GetHashCode(); if (OptionalString.Length != 0) hash ^= OptionalString.GetHashCode(); if (OptionalBytes.Length != 0) hash ^= OptionalBytes.GetHashCode(); @@ -1914,16 +1918,16 @@ namespace ProtobufTestMessages.Proto3 { if (oneofFieldCase_ == OneofFieldOneofCase.OneofBytes) hash ^= OneofBytes.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.OneofBool) hash ^= OneofBool.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.OneofUint64) hash ^= OneofUint64.GetHashCode(); - if (oneofFieldCase_ == OneofFieldOneofCase.OneofFloat) hash ^= OneofFloat.GetHashCode(); - if (oneofFieldCase_ == OneofFieldOneofCase.OneofDouble) hash ^= OneofDouble.GetHashCode(); + if (oneofFieldCase_ == OneofFieldOneofCase.OneofFloat) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(OneofFloat); + if (oneofFieldCase_ == OneofFieldOneofCase.OneofDouble) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(OneofDouble); if (oneofFieldCase_ == OneofFieldOneofCase.OneofEnum) hash ^= OneofEnum.GetHashCode(); if (optionalBoolWrapper_ != null) hash ^= OptionalBoolWrapper.GetHashCode(); if (optionalInt32Wrapper_ != null) hash ^= OptionalInt32Wrapper.GetHashCode(); if (optionalInt64Wrapper_ != null) hash ^= OptionalInt64Wrapper.GetHashCode(); if (optionalUint32Wrapper_ != null) hash ^= OptionalUint32Wrapper.GetHashCode(); if (optionalUint64Wrapper_ != null) hash ^= OptionalUint64Wrapper.GetHashCode(); - if (optionalFloatWrapper_ != null) hash ^= OptionalFloatWrapper.GetHashCode(); - if (optionalDoubleWrapper_ != null) hash ^= OptionalDoubleWrapper.GetHashCode(); + if (optionalFloatWrapper_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.GetHashCode(OptionalFloatWrapper); + if (optionalDoubleWrapper_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(OptionalDoubleWrapper); if (optionalStringWrapper_ != null) hash ^= OptionalStringWrapper.GetHashCode(); if (optionalBytesWrapper_ != null) hash ^= OptionalBytesWrapper.GetHashCode(); hash ^= repeatedBoolWrapper_.GetHashCode(); @@ -1966,6 +1970,9 @@ namespace ProtobufTestMessages.Proto3 { if (FieldName17 != 0) hash ^= FieldName17.GetHashCode(); if (FieldName18 != 0) hash ^= FieldName18.GetHashCode(); hash ^= (int) oneofFieldCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2278,6 +2285,9 @@ namespace ProtobufTestMessages.Proto3 { output.WriteRawTag(144, 26); output.WriteInt32(FieldName18); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2530,6 +2540,9 @@ namespace ProtobufTestMessages.Proto3 { if (FieldName18 != 0) { size += 2 + pb::CodedOutputStream.ComputeInt32Size(FieldName18); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2808,7 +2821,10 @@ namespace ProtobufTestMessages.Proto3 { OneofUint32 = other.OneofUint32; break; case OneofFieldOneofCase.OneofNestedMessage: - OneofNestedMessage = other.OneofNestedMessage; + if (OneofNestedMessage == null) { + OneofNestedMessage = new global::ProtobufTestMessages.Proto3.TestAllTypesProto3.Types.NestedMessage(); + } + OneofNestedMessage.MergeFrom(other.OneofNestedMessage); break; case OneofFieldOneofCase.OneofString: OneofString = other.OneofString; @@ -2833,6 +2849,7 @@ namespace ProtobufTestMessages.Proto3 { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2841,7 +2858,7 @@ namespace ProtobufTestMessages.Proto3 { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { OptionalInt32 = input.ReadInt32(); @@ -3414,6 +3431,7 @@ namespace ProtobufTestMessages.Proto3 { public sealed partial class NestedMessage : pb::IMessage<NestedMessage> { private static readonly pb::MessageParser<NestedMessage> _parser = new pb::MessageParser<NestedMessage>(() => new NestedMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedMessage> Parser { get { return _parser; } } @@ -3438,6 +3456,7 @@ namespace ProtobufTestMessages.Proto3 { public NestedMessage(NestedMessage other) : this() { a_ = other.a_; Corecursive = other.corecursive_ != null ? other.Corecursive.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3482,7 +3501,7 @@ namespace ProtobufTestMessages.Proto3 { } if (A != other.A) return false; if (!object.Equals(Corecursive, other.Corecursive)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3490,6 +3509,9 @@ namespace ProtobufTestMessages.Proto3 { int hash = 1; if (A != 0) hash ^= A.GetHashCode(); if (corecursive_ != null) hash ^= Corecursive.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3508,6 +3530,9 @@ namespace ProtobufTestMessages.Proto3 { output.WriteRawTag(18); output.WriteMessage(Corecursive); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3519,6 +3544,9 @@ namespace ProtobufTestMessages.Proto3 { if (corecursive_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Corecursive); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3536,6 +3564,7 @@ namespace ProtobufTestMessages.Proto3 { } Corecursive.MergeFrom(other.Corecursive); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3544,7 +3573,7 @@ namespace ProtobufTestMessages.Proto3 { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { A = input.ReadInt32(); @@ -3570,6 +3599,7 @@ namespace ProtobufTestMessages.Proto3 { public sealed partial class ForeignMessage : pb::IMessage<ForeignMessage> { private static readonly pb::MessageParser<ForeignMessage> _parser = new pb::MessageParser<ForeignMessage>(() => new ForeignMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ForeignMessage> Parser { get { return _parser; } } @@ -3593,6 +3623,7 @@ namespace ProtobufTestMessages.Proto3 { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ForeignMessage(ForeignMessage other) : this() { c_ = other.c_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3625,13 +3656,16 @@ namespace ProtobufTestMessages.Proto3 { return true; } if (C != other.C) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (C != 0) hash ^= C.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3646,6 +3680,9 @@ namespace ProtobufTestMessages.Proto3 { output.WriteRawTag(8); output.WriteInt32(C); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3654,6 +3691,9 @@ namespace ProtobufTestMessages.Proto3 { if (C != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(C); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3665,6 +3705,7 @@ namespace ProtobufTestMessages.Proto3 { if (other.C != 0) { C = other.C; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3673,7 +3714,7 @@ namespace ProtobufTestMessages.Proto3 { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { C = input.ReadInt32(); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestCustomOptionsProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestCustomOptionsProto3.cs index e21ede9c..6d02bda6 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestCustomOptionsProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestCustomOptionsProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: unittest_custom_options_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_custom_options_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -183,6 +185,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class TestMessageWithCustomOptions : pb::IMessage<TestMessageWithCustomOptions> { private static readonly pb::MessageParser<TestMessageWithCustomOptions> _parser = new pb::MessageParser<TestMessageWithCustomOptions>(() => new TestMessageWithCustomOptions()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMessageWithCustomOptions> Parser { get { return _parser; } } @@ -212,6 +215,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -275,7 +279,7 @@ namespace UnitTest.Issues.TestProtos { if (Field1 != other.Field1) return false; if (OneofField != other.OneofField) return false; if (AnOneofCase != other.AnOneofCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -284,6 +288,9 @@ namespace UnitTest.Issues.TestProtos { if (Field1.Length != 0) hash ^= Field1.GetHashCode(); if (anOneofCase_ == AnOneofOneofCase.OneofField) hash ^= OneofField.GetHashCode(); hash ^= (int) anOneofCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -302,6 +309,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(16); output.WriteInt32(OneofField); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -313,6 +323,9 @@ namespace UnitTest.Issues.TestProtos { if (anOneofCase_ == AnOneofOneofCase.OneofField) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(OneofField); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -330,6 +343,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -338,7 +352,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Field1 = input.ReadString(); @@ -373,6 +387,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class CustomOptionFooRequest : pb::IMessage<CustomOptionFooRequest> { private static readonly pb::MessageParser<CustomOptionFooRequest> _parser = new pb::MessageParser<CustomOptionFooRequest>(() => new CustomOptionFooRequest()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionFooRequest> Parser { get { return _parser; } } @@ -395,6 +410,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionFooRequest(CustomOptionFooRequest other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -415,12 +431,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -431,11 +450,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -444,6 +469,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -452,7 +478,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -462,6 +488,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionFooResponse : pb::IMessage<CustomOptionFooResponse> { private static readonly pb::MessageParser<CustomOptionFooResponse> _parser = new pb::MessageParser<CustomOptionFooResponse>(() => new CustomOptionFooResponse()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionFooResponse> Parser { get { return _parser; } } @@ -484,6 +511,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionFooResponse(CustomOptionFooResponse other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -504,12 +532,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -520,11 +551,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -533,6 +570,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -541,7 +579,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -551,6 +589,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionFooClientMessage : pb::IMessage<CustomOptionFooClientMessage> { private static readonly pb::MessageParser<CustomOptionFooClientMessage> _parser = new pb::MessageParser<CustomOptionFooClientMessage>(() => new CustomOptionFooClientMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionFooClientMessage> Parser { get { return _parser; } } @@ -573,6 +612,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionFooClientMessage(CustomOptionFooClientMessage other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -593,12 +633,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -609,11 +652,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -622,6 +671,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -630,7 +680,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -640,6 +690,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionFooServerMessage : pb::IMessage<CustomOptionFooServerMessage> { private static readonly pb::MessageParser<CustomOptionFooServerMessage> _parser = new pb::MessageParser<CustomOptionFooServerMessage>(() => new CustomOptionFooServerMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionFooServerMessage> Parser { get { return _parser; } } @@ -662,6 +713,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionFooServerMessage(CustomOptionFooServerMessage other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -682,12 +734,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -698,11 +753,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -711,6 +772,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -719,7 +781,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -729,6 +791,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class DummyMessageContainingEnum : pb::IMessage<DummyMessageContainingEnum> { private static readonly pb::MessageParser<DummyMessageContainingEnum> _parser = new pb::MessageParser<DummyMessageContainingEnum>(() => new DummyMessageContainingEnum()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<DummyMessageContainingEnum> Parser { get { return _parser; } } @@ -751,6 +814,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public DummyMessageContainingEnum(DummyMessageContainingEnum other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -771,12 +835,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -787,11 +854,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -800,6 +873,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -808,7 +882,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -831,6 +905,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class DummyMessageInvalidAsOptionType : pb::IMessage<DummyMessageInvalidAsOptionType> { private static readonly pb::MessageParser<DummyMessageInvalidAsOptionType> _parser = new pb::MessageParser<DummyMessageInvalidAsOptionType>(() => new DummyMessageInvalidAsOptionType()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<DummyMessageInvalidAsOptionType> Parser { get { return _parser; } } @@ -853,6 +928,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public DummyMessageInvalidAsOptionType(DummyMessageInvalidAsOptionType other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -873,12 +949,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -889,11 +968,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -902,6 +987,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -910,7 +996,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -920,6 +1006,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionMinIntegerValues : pb::IMessage<CustomOptionMinIntegerValues> { private static readonly pb::MessageParser<CustomOptionMinIntegerValues> _parser = new pb::MessageParser<CustomOptionMinIntegerValues>(() => new CustomOptionMinIntegerValues()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionMinIntegerValues> Parser { get { return _parser; } } @@ -942,6 +1029,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionMinIntegerValues(CustomOptionMinIntegerValues other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -962,12 +1050,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -978,11 +1069,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -991,6 +1088,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -999,7 +1097,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1009,6 +1107,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionMaxIntegerValues : pb::IMessage<CustomOptionMaxIntegerValues> { private static readonly pb::MessageParser<CustomOptionMaxIntegerValues> _parser = new pb::MessageParser<CustomOptionMaxIntegerValues>(() => new CustomOptionMaxIntegerValues()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionMaxIntegerValues> Parser { get { return _parser; } } @@ -1031,6 +1130,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionMaxIntegerValues(CustomOptionMaxIntegerValues other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1051,12 +1151,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1067,11 +1170,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1080,6 +1189,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1088,7 +1198,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1098,6 +1208,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class CustomOptionOtherValues : pb::IMessage<CustomOptionOtherValues> { private static readonly pb::MessageParser<CustomOptionOtherValues> _parser = new pb::MessageParser<CustomOptionOtherValues>(() => new CustomOptionOtherValues()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<CustomOptionOtherValues> Parser { get { return _parser; } } @@ -1120,6 +1231,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public CustomOptionOtherValues(CustomOptionOtherValues other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1140,12 +1252,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1156,11 +1271,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1169,6 +1290,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1177,7 +1299,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1187,6 +1309,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class SettingRealsFromPositiveInts : pb::IMessage<SettingRealsFromPositiveInts> { private static readonly pb::MessageParser<SettingRealsFromPositiveInts> _parser = new pb::MessageParser<SettingRealsFromPositiveInts>(() => new SettingRealsFromPositiveInts()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<SettingRealsFromPositiveInts> Parser { get { return _parser; } } @@ -1209,6 +1332,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public SettingRealsFromPositiveInts(SettingRealsFromPositiveInts other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1229,12 +1353,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1245,11 +1372,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1258,6 +1391,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1266,7 +1400,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1276,6 +1410,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class SettingRealsFromNegativeInts : pb::IMessage<SettingRealsFromNegativeInts> { private static readonly pb::MessageParser<SettingRealsFromNegativeInts> _parser = new pb::MessageParser<SettingRealsFromNegativeInts>(() => new SettingRealsFromNegativeInts()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<SettingRealsFromNegativeInts> Parser { get { return _parser; } } @@ -1298,6 +1433,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public SettingRealsFromNegativeInts(SettingRealsFromNegativeInts other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1318,12 +1454,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1334,11 +1473,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1347,6 +1492,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1355,7 +1501,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1365,6 +1511,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class ComplexOptionType1 : pb::IMessage<ComplexOptionType1> { private static readonly pb::MessageParser<ComplexOptionType1> _parser = new pb::MessageParser<ComplexOptionType1>(() => new ComplexOptionType1()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ComplexOptionType1> Parser { get { return _parser; } } @@ -1391,6 +1538,7 @@ namespace UnitTest.Issues.TestProtos { foo2_ = other.foo2_; foo3_ = other.foo3_; foo4_ = other.foo4_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1458,7 +1606,7 @@ namespace UnitTest.Issues.TestProtos { if (Foo2 != other.Foo2) return false; if (Foo3 != other.Foo3) return false; if(!foo4_.Equals(other.foo4_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1468,6 +1616,9 @@ namespace UnitTest.Issues.TestProtos { if (Foo2 != 0) hash ^= Foo2.GetHashCode(); if (Foo3 != 0) hash ^= Foo3.GetHashCode(); hash ^= foo4_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1491,6 +1642,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteInt32(Foo3); } foo4_.WriteTo(output, _repeated_foo4_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1506,6 +1660,9 @@ namespace UnitTest.Issues.TestProtos { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Foo3); } size += foo4_.CalculateSize(_repeated_foo4_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1524,6 +1681,7 @@ namespace UnitTest.Issues.TestProtos { Foo3 = other.Foo3; } foo4_.Add(other.foo4_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1532,7 +1690,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Foo = input.ReadInt32(); @@ -1559,6 +1717,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class ComplexOptionType2 : pb::IMessage<ComplexOptionType2> { private static readonly pb::MessageParser<ComplexOptionType2> _parser = new pb::MessageParser<ComplexOptionType2>(() => new ComplexOptionType2()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ComplexOptionType2> Parser { get { return _parser; } } @@ -1585,6 +1744,7 @@ namespace UnitTest.Issues.TestProtos { baz_ = other.baz_; Fred = other.fred_ != null ? other.Fred.Clone() : null; barney_ = other.barney_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1652,7 +1812,7 @@ namespace UnitTest.Issues.TestProtos { if (Baz != other.Baz) return false; if (!object.Equals(Fred, other.Fred)) return false; if(!barney_.Equals(other.barney_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1662,6 +1822,9 @@ namespace UnitTest.Issues.TestProtos { if (Baz != 0) hash ^= Baz.GetHashCode(); if (fred_ != null) hash ^= Fred.GetHashCode(); hash ^= barney_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1685,6 +1848,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteMessage(Fred); } barney_.WriteTo(output, _repeated_barney_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1700,6 +1866,9 @@ namespace UnitTest.Issues.TestProtos { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Fred); } size += barney_.CalculateSize(_repeated_barney_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1724,6 +1893,7 @@ namespace UnitTest.Issues.TestProtos { Fred.MergeFrom(other.Fred); } barney_.Add(other.barney_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1732,7 +1902,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (bar_ == null) { @@ -1766,6 +1936,7 @@ namespace UnitTest.Issues.TestProtos { public static partial class Types { public sealed partial class ComplexOptionType4 : pb::IMessage<ComplexOptionType4> { private static readonly pb::MessageParser<ComplexOptionType4> _parser = new pb::MessageParser<ComplexOptionType4>(() => new ComplexOptionType4()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ComplexOptionType4> Parser { get { return _parser; } } @@ -1789,6 +1960,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ComplexOptionType4(ComplexOptionType4 other) : this() { waldo_ = other.waldo_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1821,13 +1993,16 @@ namespace UnitTest.Issues.TestProtos { return true; } if (Waldo != other.Waldo) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Waldo != 0) hash ^= Waldo.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1842,6 +2017,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(8); output.WriteInt32(Waldo); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1850,6 +2028,9 @@ namespace UnitTest.Issues.TestProtos { if (Waldo != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Waldo); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1861,6 +2042,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Waldo != 0) { Waldo = other.Waldo; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1869,7 +2051,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Waldo = input.ReadInt32(); @@ -1888,6 +2070,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class ComplexOptionType3 : pb::IMessage<ComplexOptionType3> { private static readonly pb::MessageParser<ComplexOptionType3> _parser = new pb::MessageParser<ComplexOptionType3>(() => new ComplexOptionType3()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ComplexOptionType3> Parser { get { return _parser; } } @@ -1911,6 +2094,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ComplexOptionType3(ComplexOptionType3 other) : this() { qux_ = other.qux_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1943,13 +2127,16 @@ namespace UnitTest.Issues.TestProtos { return true; } if (Qux != other.Qux) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Qux != 0) hash ^= Qux.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1964,6 +2151,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(8); output.WriteInt32(Qux); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1972,6 +2162,9 @@ namespace UnitTest.Issues.TestProtos { if (Qux != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Qux); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1983,6 +2176,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Qux != 0) { Qux = other.Qux; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1991,7 +2185,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Qux = input.ReadInt32(); @@ -2008,6 +2202,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class VariousComplexOptions : pb::IMessage<VariousComplexOptions> { private static readonly pb::MessageParser<VariousComplexOptions> _parser = new pb::MessageParser<VariousComplexOptions>(() => new VariousComplexOptions()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<VariousComplexOptions> Parser { get { return _parser; } } @@ -2030,6 +2225,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public VariousComplexOptions(VariousComplexOptions other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2050,12 +2246,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2066,11 +2265,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2079,6 +2284,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2087,7 +2293,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -2100,6 +2306,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class Aggregate : pb::IMessage<Aggregate> { private static readonly pb::MessageParser<Aggregate> _parser = new pb::MessageParser<Aggregate>(() => new Aggregate()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Aggregate> Parser { get { return _parser; } } @@ -2125,6 +2332,7 @@ namespace UnitTest.Issues.TestProtos { i_ = other.i_; s_ = other.s_; Sub = other.sub_ != null ? other.Sub.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2184,7 +2392,7 @@ namespace UnitTest.Issues.TestProtos { if (I != other.I) return false; if (S != other.S) return false; if (!object.Equals(Sub, other.Sub)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2193,6 +2401,9 @@ namespace UnitTest.Issues.TestProtos { if (I != 0) hash ^= I.GetHashCode(); if (S.Length != 0) hash ^= S.GetHashCode(); if (sub_ != null) hash ^= Sub.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2215,6 +2426,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(26); output.WriteMessage(Sub); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2229,6 +2443,9 @@ namespace UnitTest.Issues.TestProtos { if (sub_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Sub); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2249,6 +2466,7 @@ namespace UnitTest.Issues.TestProtos { } Sub.MergeFrom(other.Sub); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2257,7 +2475,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { I = input.ReadInt32(); @@ -2282,6 +2500,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class AggregateMessage : pb::IMessage<AggregateMessage> { private static readonly pb::MessageParser<AggregateMessage> _parser = new pb::MessageParser<AggregateMessage>(() => new AggregateMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<AggregateMessage> Parser { get { return _parser; } } @@ -2305,6 +2524,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public AggregateMessage(AggregateMessage other) : this() { fieldname_ = other.fieldname_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2337,13 +2557,16 @@ namespace UnitTest.Issues.TestProtos { return true; } if (Fieldname != other.Fieldname) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Fieldname != 0) hash ^= Fieldname.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2358,6 +2581,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(8); output.WriteInt32(Fieldname); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2366,6 +2592,9 @@ namespace UnitTest.Issues.TestProtos { if (Fieldname != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Fieldname); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2377,6 +2606,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Fieldname != 0) { Fieldname = other.Fieldname; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2385,7 +2615,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Fieldname = input.ReadInt32(); @@ -2402,6 +2632,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class NestedOptionType : pb::IMessage<NestedOptionType> { private static readonly pb::MessageParser<NestedOptionType> _parser = new pb::MessageParser<NestedOptionType>(() => new NestedOptionType()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedOptionType> Parser { get { return _parser; } } @@ -2424,6 +2655,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public NestedOptionType(NestedOptionType other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2444,12 +2676,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2460,11 +2695,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2473,6 +2714,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2481,7 +2723,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -2498,6 +2740,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class NestedMessage : pb::IMessage<NestedMessage> { private static readonly pb::MessageParser<NestedMessage> _parser = new pb::MessageParser<NestedMessage>(() => new NestedMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedMessage> Parser { get { return _parser; } } @@ -2521,6 +2764,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public NestedMessage(NestedMessage other) : this() { nestedField_ = other.nestedField_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2553,13 +2797,16 @@ namespace UnitTest.Issues.TestProtos { return true; } if (NestedField != other.NestedField) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (NestedField != 0) hash ^= NestedField.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2574,6 +2821,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(8); output.WriteInt32(NestedField); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2582,6 +2832,9 @@ namespace UnitTest.Issues.TestProtos { if (NestedField != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(NestedField); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2593,6 +2846,7 @@ namespace UnitTest.Issues.TestProtos { if (other.NestedField != 0) { NestedField = other.NestedField; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2601,7 +2855,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { NestedField = input.ReadInt32(); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportProto3.cs index f6df4e87..6bf97151 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_import_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_import_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -9,11 +11,11 @@ using pbr = global::Google.Protobuf.Reflection; using scg = global::System.Collections.Generic; namespace Google.Protobuf.TestProtos { - /// <summary>Holder for reflection information generated from google/protobuf/unittest_import_proto3.proto</summary> + /// <summary>Holder for reflection information generated from unittest_import_proto3.proto</summary> public static partial class UnittestImportProto3Reflection { #region Descriptor - /// <summary>File descriptor for google/protobuf/unittest_import_proto3.proto</summary> + /// <summary>File descriptor for unittest_import_proto3.proto</summary> public static pbr::FileDescriptor Descriptor { get { return descriptor; } } @@ -22,14 +24,12 @@ namespace Google.Protobuf.TestProtos { static UnittestImportProto3Reflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "Cixnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0X3Byb3RvMy5wcm90", - "bxIYcHJvdG9idWZfdW5pdHRlc3RfaW1wb3J0GjNnb29nbGUvcHJvdG9idWYv", - "dW5pdHRlc3RfaW1wb3J0X3B1YmxpY19wcm90bzMucHJvdG8iGgoNSW1wb3J0", - "TWVzc2FnZRIJCgFkGAEgASgFKlkKCkltcG9ydEVudW0SGwoXSU1QT1JUX0VO", - "VU1fVU5TUEVDSUZJRUQQABIOCgpJTVBPUlRfRk9PEAcSDgoKSU1QT1JUX0JB", - "UhAIEg4KCklNUE9SVF9CQVoQCUI8Chhjb20uZ29vZ2xlLnByb3RvYnVmLnRl", - "c3RIAfgBAaoCGkdvb2dsZS5Qcm90b2J1Zi5UZXN0UHJvdG9zUABiBnByb3Rv", - "Mw==")); + "Chx1bml0dGVzdF9pbXBvcnRfcHJvdG8zLnByb3RvEhhwcm90b2J1Zl91bml0", + "dGVzdF9pbXBvcnQaI3VuaXR0ZXN0X2ltcG9ydF9wdWJsaWNfcHJvdG8zLnBy", + "b3RvIhoKDUltcG9ydE1lc3NhZ2USCQoBZBgBIAEoBSpZCgpJbXBvcnRFbnVt", + "EhsKF0lNUE9SVF9FTlVNX1VOU1BFQ0lGSUVEEAASDgoKSU1QT1JUX0ZPTxAH", + "Eg4KCklNUE9SVF9CQVIQCBIOCgpJTVBPUlRfQkFaEAlCHaoCGkdvb2dsZS5Q", + "cm90b2J1Zi5UZXN0UHJvdG9zUABiBnByb3RvMw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Google.Protobuf.TestProtos.UnittestImportPublicProto3Reflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Google.Protobuf.TestProtos.ImportEnum), }, new pbr::GeneratedClrTypeInfo[] { @@ -52,6 +52,7 @@ namespace Google.Protobuf.TestProtos { #region Messages public sealed partial class ImportMessage : pb::IMessage<ImportMessage> { private static readonly pb::MessageParser<ImportMessage> _parser = new pb::MessageParser<ImportMessage>(() => new ImportMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ImportMessage> Parser { get { return _parser; } } @@ -75,6 +76,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ImportMessage(ImportMessage other) : this() { d_ = other.d_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -107,13 +109,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (D != other.D) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (D != 0) hash ^= D.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -128,6 +133,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(D); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -136,6 +144,9 @@ namespace Google.Protobuf.TestProtos { if (D != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(D); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -147,6 +158,7 @@ namespace Google.Protobuf.TestProtos { if (other.D != 0) { D = other.D; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -155,7 +167,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { D = input.ReadInt32(); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportPublicProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportPublicProto3.cs index 67b8edf4..97d181af 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportPublicProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestImportPublicProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_import_public_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_import_public_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -9,11 +11,11 @@ using pbr = global::Google.Protobuf.Reflection; using scg = global::System.Collections.Generic; namespace Google.Protobuf.TestProtos { - /// <summary>Holder for reflection information generated from google/protobuf/unittest_import_public_proto3.proto</summary> + /// <summary>Holder for reflection information generated from unittest_import_public_proto3.proto</summary> public static partial class UnittestImportPublicProto3Reflection { #region Descriptor - /// <summary>File descriptor for google/protobuf/unittest_import_public_proto3.proto</summary> + /// <summary>File descriptor for unittest_import_public_proto3.proto</summary> public static pbr::FileDescriptor Descriptor { get { return descriptor; } } @@ -22,10 +24,10 @@ namespace Google.Protobuf.TestProtos { static UnittestImportPublicProto3Reflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "CjNnb29nbGUvcHJvdG9idWYvdW5pdHRlc3RfaW1wb3J0X3B1YmxpY19wcm90", - "bzMucHJvdG8SGHByb3RvYnVmX3VuaXR0ZXN0X2ltcG9ydCIgChNQdWJsaWNJ", - "bXBvcnRNZXNzYWdlEgkKAWUYASABKAVCNwoYY29tLmdvb2dsZS5wcm90b2J1", - "Zi50ZXN0qgIaR29vZ2xlLlByb3RvYnVmLlRlc3RQcm90b3NiBnByb3RvMw==")); + "CiN1bml0dGVzdF9pbXBvcnRfcHVibGljX3Byb3RvMy5wcm90bxIYcHJvdG9i", + "dWZfdW5pdHRlc3RfaW1wb3J0IiAKE1B1YmxpY0ltcG9ydE1lc3NhZ2USCQoB", + "ZRgBIAEoBUIdqgIaR29vZ2xlLlByb3RvYnVmLlRlc3RQcm90b3NiBnByb3Rv", + "Mw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { }, new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] { @@ -38,6 +40,7 @@ namespace Google.Protobuf.TestProtos { #region Messages public sealed partial class PublicImportMessage : pb::IMessage<PublicImportMessage> { private static readonly pb::MessageParser<PublicImportMessage> _parser = new pb::MessageParser<PublicImportMessage>(() => new PublicImportMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<PublicImportMessage> Parser { get { return _parser; } } @@ -61,6 +64,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public PublicImportMessage(PublicImportMessage other) : this() { e_ = other.e_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -93,13 +97,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (E != other.E) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (E != 0) hash ^= E.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -114,6 +121,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(E); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -122,6 +132,9 @@ namespace Google.Protobuf.TestProtos { if (E != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(E); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -133,6 +146,7 @@ namespace Google.Protobuf.TestProtos { if (other.E != 0) { E = other.E; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -141,7 +155,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { E = input.ReadInt32(); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestIssues.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestIssues.cs index cbf7909c..01a86f8f 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestIssues.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestIssues.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: unittest_issues.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_issues.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -48,8 +50,8 @@ namespace UnitTest.Issues.TestProtos { "GAEgASgFEgkKAXkYAiABKAVCBwoFdmFsdWUqVQoMTmVnYXRpdmVFbnVtEhYK", "Ek5FR0FUSVZFX0VOVU1fWkVSTxAAEhYKCUZpdmVCZWxvdxD7//////////8B", "EhUKCE1pbnVzT25lEP///////////wEqLgoORGVwcmVjYXRlZEVudW0SEwoP", - "REVQUkVDQVRFRF9aRVJPEAASBwoDb25lEAFCH0gBqgIaVW5pdFRlc3QuSXNz", - "dWVzLlRlc3RQcm90b3NiBnByb3RvMw==")); + "REVQUkVDQVRFRF9aRVJPEAASBwoDb25lEAFCHaoCGlVuaXRUZXN0Lklzc3Vl", + "cy5UZXN0UHJvdG9zYgZwcm90bzM=")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::UnitTest.Issues.TestProtos.NegativeEnum), typeof(global::UnitTest.Issues.TestProtos.DeprecatedEnum), }, new pbr::GeneratedClrTypeInfo[] { @@ -88,6 +90,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class Issue307 : pb::IMessage<Issue307> { private static readonly pb::MessageParser<Issue307> _parser = new pb::MessageParser<Issue307>(() => new Issue307()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Issue307> Parser { get { return _parser; } } @@ -110,6 +113,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Issue307(Issue307 other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -130,12 +134,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -146,11 +153,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -159,6 +172,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -167,7 +181,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -179,6 +193,7 @@ namespace UnitTest.Issues.TestProtos { public static partial class Types { public sealed partial class NestedOnce : pb::IMessage<NestedOnce> { private static readonly pb::MessageParser<NestedOnce> _parser = new pb::MessageParser<NestedOnce>(() => new NestedOnce()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedOnce> Parser { get { return _parser; } } @@ -201,6 +216,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public NestedOnce(NestedOnce other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -221,12 +237,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -237,11 +256,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -250,6 +275,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -258,7 +284,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -270,6 +296,7 @@ namespace UnitTest.Issues.TestProtos { public static partial class Types { public sealed partial class NestedTwice : pb::IMessage<NestedTwice> { private static readonly pb::MessageParser<NestedTwice> _parser = new pb::MessageParser<NestedTwice>(() => new NestedTwice()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedTwice> Parser { get { return _parser; } } @@ -292,6 +319,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public NestedTwice(NestedTwice other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -312,12 +340,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -328,11 +359,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -341,6 +378,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -349,7 +387,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -369,6 +407,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class NegativeEnumMessage : pb::IMessage<NegativeEnumMessage> { private static readonly pb::MessageParser<NegativeEnumMessage> _parser = new pb::MessageParser<NegativeEnumMessage>(() => new NegativeEnumMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NegativeEnumMessage> Parser { get { return _parser; } } @@ -394,6 +433,7 @@ namespace UnitTest.Issues.TestProtos { value_ = other.value_; values_ = other.values_.Clone(); packedValues_ = other.packedValues_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -448,7 +488,7 @@ namespace UnitTest.Issues.TestProtos { if (Value != other.Value) return false; if(!values_.Equals(other.values_)) return false; if(!packedValues_.Equals(other.packedValues_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -457,6 +497,9 @@ namespace UnitTest.Issues.TestProtos { if (Value != 0) hash ^= Value.GetHashCode(); hash ^= values_.GetHashCode(); hash ^= packedValues_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -473,6 +516,9 @@ namespace UnitTest.Issues.TestProtos { } values_.WriteTo(output, _repeated_values_codec); packedValues_.WriteTo(output, _repeated_packedValues_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -483,6 +529,9 @@ namespace UnitTest.Issues.TestProtos { } size += values_.CalculateSize(_repeated_values_codec); size += packedValues_.CalculateSize(_repeated_packedValues_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -496,6 +545,7 @@ namespace UnitTest.Issues.TestProtos { } values_.Add(other.values_); packedValues_.Add(other.packedValues_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -504,7 +554,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { value_ = (global::UnitTest.Issues.TestProtos.NegativeEnum) input.ReadEnum(); @@ -528,6 +578,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class DeprecatedChild : pb::IMessage<DeprecatedChild> { private static readonly pb::MessageParser<DeprecatedChild> _parser = new pb::MessageParser<DeprecatedChild>(() => new DeprecatedChild()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<DeprecatedChild> Parser { get { return _parser; } } @@ -550,6 +601,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public DeprecatedChild(DeprecatedChild other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -570,12 +622,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -586,11 +641,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -599,6 +660,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -607,7 +669,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -617,6 +679,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class DeprecatedFieldsMessage : pb::IMessage<DeprecatedFieldsMessage> { private static readonly pb::MessageParser<DeprecatedFieldsMessage> _parser = new pb::MessageParser<DeprecatedFieldsMessage>(() => new DeprecatedFieldsMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<DeprecatedFieldsMessage> Parser { get { return _parser; } } @@ -645,6 +708,7 @@ namespace UnitTest.Issues.TestProtos { messageArray_ = other.messageArray_.Clone(); enumValue_ = other.enumValue_; enumArray_ = other.enumArray_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -740,7 +804,7 @@ namespace UnitTest.Issues.TestProtos { if(!messageArray_.Equals(other.messageArray_)) return false; if (EnumValue != other.EnumValue) return false; if(!enumArray_.Equals(other.enumArray_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -752,6 +816,9 @@ namespace UnitTest.Issues.TestProtos { hash ^= messageArray_.GetHashCode(); if (EnumValue != 0) hash ^= EnumValue.GetHashCode(); hash ^= enumArray_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -777,6 +844,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteEnum((int) EnumValue); } enumArray_.WriteTo(output, _repeated_enumArray_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -794,6 +864,9 @@ namespace UnitTest.Issues.TestProtos { size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) EnumValue); } size += enumArray_.CalculateSize(_repeated_enumArray_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -817,6 +890,7 @@ namespace UnitTest.Issues.TestProtos { EnumValue = other.EnumValue; } enumArray_.Add(other.enumArray_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -825,7 +899,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { PrimitiveValue = input.ReadInt32(); @@ -867,6 +941,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class ItemField : pb::IMessage<ItemField> { private static readonly pb::MessageParser<ItemField> _parser = new pb::MessageParser<ItemField>(() => new ItemField()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ItemField> Parser { get { return _parser; } } @@ -890,6 +965,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ItemField(ItemField other) : this() { item_ = other.item_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -922,13 +998,16 @@ namespace UnitTest.Issues.TestProtos { return true; } if (Item != other.Item) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Item != 0) hash ^= Item.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -943,6 +1022,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(8); output.WriteInt32(Item); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -951,6 +1033,9 @@ namespace UnitTest.Issues.TestProtos { if (Item != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Item); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -962,6 +1047,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Item != 0) { Item = other.Item; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -970,7 +1056,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Item = input.ReadInt32(); @@ -984,6 +1070,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class ReservedNames : pb::IMessage<ReservedNames> { private static readonly pb::MessageParser<ReservedNames> _parser = new pb::MessageParser<ReservedNames>(() => new ReservedNames()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ReservedNames> Parser { get { return _parser; } } @@ -1008,6 +1095,7 @@ namespace UnitTest.Issues.TestProtos { public ReservedNames(ReservedNames other) : this() { types_ = other.types_; descriptor_ = other.descriptor_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1052,7 +1140,7 @@ namespace UnitTest.Issues.TestProtos { } if (Types_ != other.Types_) return false; if (Descriptor_ != other.Descriptor_) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1060,6 +1148,9 @@ namespace UnitTest.Issues.TestProtos { int hash = 1; if (Types_ != 0) hash ^= Types_.GetHashCode(); if (Descriptor_ != 0) hash ^= Descriptor_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1078,6 +1169,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(16); output.WriteInt32(Descriptor_); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1089,6 +1183,9 @@ namespace UnitTest.Issues.TestProtos { if (Descriptor_ != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Descriptor_); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1103,6 +1200,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Descriptor_ != 0) { Descriptor_ = other.Descriptor_; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1111,7 +1209,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Types_ = input.ReadInt32(); @@ -1134,6 +1232,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class SomeNestedType : pb::IMessage<SomeNestedType> { private static readonly pb::MessageParser<SomeNestedType> _parser = new pb::MessageParser<SomeNestedType>(() => new SomeNestedType()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<SomeNestedType> Parser { get { return _parser; } } @@ -1156,6 +1255,7 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public SomeNestedType(SomeNestedType other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1176,12 +1276,15 @@ namespace UnitTest.Issues.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1192,11 +1295,17 @@ namespace UnitTest.Issues.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1205,6 +1314,7 @@ namespace UnitTest.Issues.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1213,7 +1323,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -1240,6 +1350,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class TestJsonFieldOrdering : pb::IMessage<TestJsonFieldOrdering> { private static readonly pb::MessageParser<TestJsonFieldOrdering> _parser = new pb::MessageParser<TestJsonFieldOrdering>(() => new TestJsonFieldOrdering()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestJsonFieldOrdering> Parser { get { return _parser; } } @@ -1282,6 +1393,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1414,7 +1526,7 @@ namespace UnitTest.Issues.TestProtos { if (O2String != other.O2String) return false; if (O1Case != other.O1Case) return false; if (O2Case != other.O2Case) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1428,6 +1540,9 @@ namespace UnitTest.Issues.TestProtos { if (o2Case_ == O2OneofCase.O2String) hash ^= O2String.GetHashCode(); hash ^= (int) o1Case_; hash ^= (int) o2Case_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1462,6 +1577,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(48); output.WriteInt32(O2Int32); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1485,6 +1603,9 @@ namespace UnitTest.Issues.TestProtos { if (o2Case_ == O2OneofCase.O2String) { size += 1 + pb::CodedOutputStream.ComputeStringSize(O2String); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1517,6 +1638,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1525,7 +1647,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { PlainString = input.ReadString(); @@ -1559,6 +1681,7 @@ namespace UnitTest.Issues.TestProtos { public sealed partial class TestJsonName : pb::IMessage<TestJsonName> { private static readonly pb::MessageParser<TestJsonName> _parser = new pb::MessageParser<TestJsonName>(() => new TestJsonName()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestJsonName> Parser { get { return _parser; } } @@ -1584,6 +1707,7 @@ namespace UnitTest.Issues.TestProtos { name_ = other.name_; description_ = other.description_; guid_ = other.guid_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1643,7 +1767,7 @@ namespace UnitTest.Issues.TestProtos { if (Name != other.Name) return false; if (Description != other.Description) return false; if (Guid != other.Guid) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1652,6 +1776,9 @@ namespace UnitTest.Issues.TestProtos { if (Name.Length != 0) hash ^= Name.GetHashCode(); if (Description.Length != 0) hash ^= Description.GetHashCode(); if (Guid.Length != 0) hash ^= Guid.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1674,6 +1801,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(26); output.WriteString(Guid); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1688,6 +1818,9 @@ namespace UnitTest.Issues.TestProtos { if (Guid.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(Guid); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1705,6 +1838,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Guid.Length != 0) { Guid = other.Guid; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1713,7 +1847,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Name = input.ReadString(); @@ -1740,6 +1874,7 @@ namespace UnitTest.Issues.TestProtos { /// </summary> public sealed partial class OneofMerging : pb::IMessage<OneofMerging> { private static readonly pb::MessageParser<OneofMerging> _parser = new pb::MessageParser<OneofMerging>(() => new OneofMerging()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<OneofMerging> Parser { get { return _parser; } } @@ -1771,6 +1906,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1835,7 +1971,7 @@ namespace UnitTest.Issues.TestProtos { if (Text != other.Text) return false; if (!object.Equals(Nested, other.Nested)) return false; if (ValueCase != other.ValueCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1844,6 +1980,9 @@ namespace UnitTest.Issues.TestProtos { if (valueCase_ == ValueOneofCase.Text) hash ^= Text.GetHashCode(); if (valueCase_ == ValueOneofCase.Nested) hash ^= Nested.GetHashCode(); hash ^= (int) valueCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1862,6 +2001,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(18); output.WriteMessage(Nested); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1873,6 +2015,9 @@ namespace UnitTest.Issues.TestProtos { if (valueCase_ == ValueOneofCase.Nested) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Nested); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1893,6 +2038,7 @@ namespace UnitTest.Issues.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1901,7 +2047,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Text = input.ReadString(); @@ -1926,6 +2072,7 @@ namespace UnitTest.Issues.TestProtos { public static partial class Types { public sealed partial class Nested : pb::IMessage<Nested> { private static readonly pb::MessageParser<Nested> _parser = new pb::MessageParser<Nested>(() => new Nested()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Nested> Parser { get { return _parser; } } @@ -1950,6 +2097,7 @@ namespace UnitTest.Issues.TestProtos { public Nested(Nested other) : this() { x_ = other.x_; y_ = other.y_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1994,7 +2142,7 @@ namespace UnitTest.Issues.TestProtos { } if (X != other.X) return false; if (Y != other.Y) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2002,6 +2150,9 @@ namespace UnitTest.Issues.TestProtos { int hash = 1; if (X != 0) hash ^= X.GetHashCode(); if (Y != 0) hash ^= Y.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2020,6 +2171,9 @@ namespace UnitTest.Issues.TestProtos { output.WriteRawTag(16); output.WriteInt32(Y); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2031,6 +2185,9 @@ namespace UnitTest.Issues.TestProtos { if (Y != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Y); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2045,6 +2202,7 @@ namespace UnitTest.Issues.TestProtos { if (other.Y != 0) { Y = other.Y; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2053,7 +2211,7 @@ namespace UnitTest.Issues.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { X = input.ReadInt32(); diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestProto3.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestProto3.cs index c11ab84d..4242c192 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestProto3.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestProto3.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_proto3.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: unittest_proto3.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -9,11 +11,11 @@ using pbr = global::Google.Protobuf.Reflection; using scg = global::System.Collections.Generic; namespace Google.Protobuf.TestProtos { - /// <summary>Holder for reflection information generated from google/protobuf/unittest_proto3.proto</summary> + /// <summary>Holder for reflection information generated from unittest_proto3.proto</summary> public static partial class UnittestProto3Reflection { #region Descriptor - /// <summary>File descriptor for google/protobuf/unittest_proto3.proto</summary> + /// <summary>File descriptor for unittest_proto3.proto</summary> public static pbr::FileDescriptor Descriptor { get { return descriptor; } } @@ -22,135 +24,135 @@ namespace Google.Protobuf.TestProtos { static UnittestProto3Reflection() { byte[] descriptorData = global::System.Convert.FromBase64String( string.Concat( - "CiVnb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wKBGRhdGEYASABKAMiHQoNVWludDY0TWVzc2FnZRIMCgRkYXRhGAEgASgE", - "IhsKC0Jvb2xNZXNzYWdlEgwKBGRhdGEYASABKAgicwoJVGVzdE9uZW9mEhEK", - "B2Zvb19pbnQYASABKAVIABIUCgpmb29fc3RyaW5nGAIgASgJSAASNgoLZm9v", - "X21lc3NhZ2UYAyABKAsyHy5wcm90b2J1Zl91bml0dGVzdC5UZXN0QWxsVHlw", - "ZXNIAEIFCgNmb28iqgMKD1Rlc3RQYWNrZWRUeXBlcxIYCgxwYWNrZWRfaW50", - "MzIYWiADKAVCAhABEhgKDHBhY2tlZF9pbnQ2NBhbIAMoA0ICEAESGQoNcGFj", - "a2VkX3VpbnQzMhhcIAMoDUICEAESGQoNcGFja2VkX3VpbnQ2NBhdIAMoBEIC", - "EAESGQoNcGFja2VkX3NpbnQzMhheIAMoEUICEAESGQoNcGFja2VkX3NpbnQ2", - "NBhfIAMoEkICEAESGgoOcGFja2VkX2ZpeGVkMzIYYCADKAdCAhABEhoKDnBh", - "Y2tlZF9maXhlZDY0GGEgAygGQgIQARIbCg9wYWNrZWRfc2ZpeGVkMzIYYiAD", - "KA9CAhABEhsKD3BhY2tlZF9zZml4ZWQ2NBhjIAMoEEICEAESGAoMcGFja2Vk", - "X2Zsb2F0GGQgAygCQgIQARIZCg1wYWNrZWRfZG91YmxlGGUgAygBQgIQARIX", - "CgtwYWNrZWRfYm9vbBhmIAMoCEICEAESNwoLcGFja2VkX2VudW0YZyADKA4y", - "Hi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bUICEAEiyAMKEVRlc3RV", - "bnBhY2tlZFR5cGVzEhoKDnVucGFja2VkX2ludDMyGFogAygFQgIQABIaCg51", - "bnBhY2tlZF9pbnQ2NBhbIAMoA0ICEAASGwoPdW5wYWNrZWRfdWludDMyGFwg", - "AygNQgIQABIbCg91bnBhY2tlZF91aW50NjQYXSADKARCAhAAEhsKD3VucGFj", - "a2VkX3NpbnQzMhheIAMoEUICEAASGwoPdW5wYWNrZWRfc2ludDY0GF8gAygS", - "QgIQABIcChB1bnBhY2tlZF9maXhlZDMyGGAgAygHQgIQABIcChB1bnBhY2tl", - "ZF9maXhlZDY0GGEgAygGQgIQABIdChF1bnBhY2tlZF9zZml4ZWQzMhhiIAMo", - "D0ICEAASHQoRdW5wYWNrZWRfc2ZpeGVkNjQYYyADKBBCAhAAEhoKDnVucGFj", - "a2VkX2Zsb2F0GGQgAygCQgIQABIbCg91bnBhY2tlZF9kb3VibGUYZSADKAFC", - "AhAAEhkKDXVucGFja2VkX2Jvb2wYZiADKAhCAhAAEjkKDXVucGFja2VkX2Vu", - "dW0YZyADKA4yHi5wcm90b2J1Zl91bml0dGVzdC5Gb3JlaWduRW51bUICEAAi", - "wAEKI1Rlc3RSZXBlYXRlZFNjYWxhckRpZmZlcmVudFRhZ1NpemVzEhgKEHJl", - "cGVhdGVkX2ZpeGVkMzIYDCADKAcSFgoOcmVwZWF0ZWRfaW50MzIYDSADKAUS", - "GQoQcmVwZWF0ZWRfZml4ZWQ2NBj+DyADKAYSFwoOcmVwZWF0ZWRfaW50NjQY", - "/w8gAygDEhgKDnJlcGVhdGVkX2Zsb2F0GP7/DyADKAISGQoPcmVwZWF0ZWRf", - "dWludDY0GP//DyADKAQiKAobVGVzdENvbW1lbnRJbmplY3Rpb25NZXNzYWdl", - "EgkKAWEYASABKAkiDAoKRm9vUmVxdWVzdCINCgtGb29SZXNwb25zZSISChBG", - "b29DbGllbnRNZXNzYWdlIhIKEEZvb1NlcnZlck1lc3NhZ2UiDAoKQmFyUmVx", - "dWVzdCINCgtCYXJSZXNwb25zZSpZCgtGb3JlaWduRW51bRIXChNGT1JFSUdO", - "X1VOU1BFQ0lGSUVEEAASDwoLRk9SRUlHTl9GT08QBBIPCgtGT1JFSUdOX0JB", - "UhAFEg8KC0ZPUkVJR05fQkFaEAYqdQoUVGVzdEVudW1XaXRoRHVwVmFsdWUS", - "KAokVEVTVF9FTlVNX1dJVEh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llbGRPcmRlcmluZ3MS", + "EQoJbXlfc3RyaW5nGAsgASgJEg4KBm15X2ludBgBIAEoAxIQCghteV9mbG9h", + "dBhlIAEoAhJUChVzaW5nbGVfbmVzdGVkX21lc3NhZ2UYyAEgASgLMjQucHJv", + "dG9idWZfdW5pdHRlc3QzLlRlc3RGaWVsZE9yZGVyaW5ncy5OZXN0ZWRNZXNz", + "YWdlGicKDU5lc3RlZE1lc3NhZ2USCgoCb28YAiABKAMSCgoCYmIYASABKAUi", + "TAoRU3BhcnNlRW51bU1lc3NhZ2USNwoLc3BhcnNlX2VudW0YASABKA4yIi5w", + "cm90b2J1Zl91bml0dGVzdDMuVGVzdFNwYXJzZUVudW0iGQoJT25lU3RyaW5n", + "EgwKBGRhdGEYASABKAkiGgoKTW9yZVN0cmluZxIMCgRkYXRhGAEgAygJIhgK", + "CE9uZUJ5dGVzEgwKBGRhdGEYASABKAwiGQoJTW9yZUJ5dGVzEgwKBGRhdGEY", + "ASABKAwiHAoMSW50MzJNZXNzYWdlEgwKBGRhdGEYASABKAUiHQoNVWludDMy", + "TWVzc2FnZRIMCgRkYXRhGAEgASgNIhwKDEludDY0TWVzc2FnZRIMCgRkYXRh", + "GAEgASgDIh0KDVVpbnQ2NE1lc3NhZ2USDAoEZGF0YRgBIAEoBCIbCgtCb29s", + "TWVzc2FnZRIMCgRkYXRhGAEgASgIInQKCVRlc3RPbmVvZhIRCgdmb29faW50", + "GAEgASgFSAASFAoKZm9vX3N0cmluZxgCIAEoCUgAEjcKC2Zvb19tZXNzYWdl", + "GAMgASgLMiAucHJvdG9idWZfdW5pdHRlc3QzLlRlc3RBbGxUeXBlc0gAQgUK", + "A2ZvbyKrAwoPVGVzdFBhY2tlZFR5cGVzEhgKDHBhY2tlZF9pbnQzMhhaIAMo", + "BUICEAESGAoMcGFja2VkX2ludDY0GFsgAygDQgIQARIZCg1wYWNrZWRfdWlu", + "dDMyGFwgAygNQgIQARIZCg1wYWNrZWRfdWludDY0GF0gAygEQgIQARIZCg1w", + "YWNrZWRfc2ludDMyGF4gAygRQgIQARIZCg1wYWNrZWRfc2ludDY0GF8gAygS", + "QgIQARIaCg5wYWNrZWRfZml4ZWQzMhhgIAMoB0ICEAESGgoOcGFja2VkX2Zp", + "eGVkNjQYYSADKAZCAhABEhsKD3BhY2tlZF9zZml4ZWQzMhhiIAMoD0ICEAES", + "GwoPcGFja2VkX3NmaXhlZDY0GGMgAygQQgIQARIYCgxwYWNrZWRfZmxvYXQY", + "ZCADKAJCAhABEhkKDXBhY2tlZF9kb3VibGUYZSADKAFCAhABEhcKC3BhY2tl", + "ZF9ib29sGGYgAygIQgIQARI4CgtwYWNrZWRfZW51bRhnIAMoDjIfLnByb3Rv", + "YnVmX3VuaXR0ZXN0My5Gb3JlaWduRW51bUICEAEiyQMKEVRlc3RVbnBhY2tl", + "ZFR5cGVzEhoKDnVucGFja2VkX2ludDMyGFogAygFQgIQABIaCg51bnBhY2tl", + "ZF9pbnQ2NBhbIAMoA0ICEAASGwoPdW5wYWNrZWRfdWludDMyGFwgAygNQgIQ", + "ABIbCg91bnBhY2tlZF91aW50NjQYXSADKARCAhAAEhsKD3VucGFja2VkX3Np", + "bnQzMhheIAMoEUICEAASGwoPdW5wYWNrZWRfc2ludDY0GF8gAygSQgIQABIc", + "ChB1bnBhY2tlZF9maXhlZDMyGGAgAygHQgIQABIcChB1bnBhY2tlZF9maXhl", + "ZDY0GGEgAygGQgIQABIdChF1bnBhY2tlZF9zZml4ZWQzMhhiIAMoD0ICEAAS", + "HQoRdW5wYWNrZWRfc2ZpeGVkNjQYYyADKBBCAhAAEhoKDnVucGFja2VkX2Zs", + "b2F0GGQgAygCQgIQABIbCg91bnBhY2tlZF9kb3VibGUYZSADKAFCAhAAEhkK", + "DXVucGFja2VkX2Jvb2wYZiADKAhCAhAAEjoKDXVucGFja2VkX2VudW0YZyAD", + "KA4yHy5wcm90b2J1Zl91bml0dGVzdDMuRm9yZWlnbkVudW1CAhAAIsABCiNU", + "ZXN0Um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G", + "b29SZXF1ZXN0Gh8ucHJvdG9idWZfdW5pdHRlc3QzLkZvb1Jlc3BvbnNlEkYK", + "A0JhchIeLnByb3RvYnVmX3VuaXR0ZXN0My5CYXJSZXF1ZXN0Gh8ucHJvdG9i", + "dWZfdW5pdHRlc3QzLkJhclJlc3BvbnNlQixCDVVuaXR0ZXN0UHJvdG+qAhpH", + "b29nbGUuUHJvdG9idWYuVGVzdFByb3Rvc2IGcHJvdG8z")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Google.Protobuf.TestProtos.UnittestImportProto3Reflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Google.Protobuf.TestProtos.ForeignEnum), typeof(global::Google.Protobuf.TestProtos.TestEnumWithDupValue), typeof(global::Google.Protobuf.TestProtos.TestSparseEnum), }, new pbr::GeneratedClrTypeInfo[] { @@ -187,7 +189,8 @@ namespace Google.Protobuf.TestProtos { new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.FooClientMessage), global::Google.Protobuf.TestProtos.FooClientMessage.Parser, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.FooServerMessage), global::Google.Protobuf.TestProtos.FooServerMessage.Parser, null, null, null, null), new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.BarRequest), global::Google.Protobuf.TestProtos.BarRequest.Parser, null, null, null, null), - new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.BarResponse), global::Google.Protobuf.TestProtos.BarResponse.Parser, null, null, null, null) + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.BarResponse), global::Google.Protobuf.TestProtos.BarResponse.Parser, null, null, null, null), + new pbr::GeneratedClrTypeInfo(typeof(global::Google.Protobuf.TestProtos.TestEmptyMessage), global::Google.Protobuf.TestProtos.TestEmptyMessage.Parser, null, null, null, null) })); } #endregion @@ -239,6 +242,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestAllTypes : pb::IMessage<TestAllTypes> { private static readonly pb::MessageParser<TestAllTypes> _parser = new pb::MessageParser<TestAllTypes>(() => new TestAllTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestAllTypes> Parser { get { return _parser; } } @@ -320,6 +324,7 @@ namespace Google.Protobuf.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -889,8 +894,8 @@ namespace Google.Protobuf.TestProtos { if (SingleFixed64 != other.SingleFixed64) return false; if (SingleSfixed32 != other.SingleSfixed32) return false; if (SingleSfixed64 != other.SingleSfixed64) return false; - if (SingleFloat != other.SingleFloat) return false; - if (SingleDouble != other.SingleDouble) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(SingleFloat, other.SingleFloat)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.Equals(SingleDouble, other.SingleDouble)) return false; if (SingleBool != other.SingleBool) return false; if (SingleString != other.SingleString) return false; if (SingleBytes != other.SingleBytes) return false; @@ -928,7 +933,7 @@ namespace Google.Protobuf.TestProtos { if (OneofString != other.OneofString) return false; if (OneofBytes != other.OneofBytes) return false; if (OneofFieldCase != other.OneofFieldCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -944,8 +949,8 @@ namespace Google.Protobuf.TestProtos { if (SingleFixed64 != 0UL) hash ^= SingleFixed64.GetHashCode(); if (SingleSfixed32 != 0) hash ^= SingleSfixed32.GetHashCode(); if (SingleSfixed64 != 0L) hash ^= SingleSfixed64.GetHashCode(); - if (SingleFloat != 0F) hash ^= SingleFloat.GetHashCode(); - if (SingleDouble != 0D) hash ^= SingleDouble.GetHashCode(); + if (SingleFloat != 0F) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(SingleFloat); + if (SingleDouble != 0D) hash ^= pbc::ProtobufEqualityComparers.BitwiseDoubleEqualityComparer.GetHashCode(SingleDouble); if (SingleBool != false) hash ^= SingleBool.GetHashCode(); if (SingleString.Length != 0) hash ^= SingleString.GetHashCode(); if (SingleBytes.Length != 0) hash ^= SingleBytes.GetHashCode(); @@ -983,6 +988,9 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.OneofString) hash ^= OneofString.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.OneofBytes) hash ^= OneofBytes.GetHashCode(); hash ^= (int) oneofFieldCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1119,6 +1127,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(146, 7); output.WriteBytes(OneofBytes); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1224,6 +1235,9 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.OneofBytes) { size += 2 + pb::CodedOutputStream.ComputeBytesSize(OneofBytes); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1337,7 +1351,10 @@ namespace Google.Protobuf.TestProtos { OneofUint32 = other.OneofUint32; break; case OneofFieldOneofCase.OneofNestedMessage: - OneofNestedMessage = other.OneofNestedMessage; + if (OneofNestedMessage == null) { + OneofNestedMessage = new global::Google.Protobuf.TestProtos.TestAllTypes.Types.NestedMessage(); + } + OneofNestedMessage.MergeFrom(other.OneofNestedMessage); break; case OneofFieldOneofCase.OneofString: OneofString = other.OneofString; @@ -1347,6 +1364,7 @@ namespace Google.Protobuf.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1355,7 +1373,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { SingleInt32 = input.ReadInt32(); @@ -1603,6 +1621,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class NestedMessage : pb::IMessage<NestedMessage> { private static readonly pb::MessageParser<NestedMessage> _parser = new pb::MessageParser<NestedMessage>(() => new NestedMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedMessage> Parser { get { return _parser; } } @@ -1626,6 +1645,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public NestedMessage(NestedMessage other) : this() { bb_ = other.bb_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1663,13 +1683,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Bb != other.Bb) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Bb != 0) hash ^= Bb.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1684,6 +1707,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(Bb); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1692,6 +1718,9 @@ namespace Google.Protobuf.TestProtos { if (Bb != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Bb); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1703,6 +1732,7 @@ namespace Google.Protobuf.TestProtos { if (other.Bb != 0) { Bb = other.Bb; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1711,7 +1741,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Bb = input.ReadInt32(); @@ -1733,6 +1763,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class NestedTestAllTypes : pb::IMessage<NestedTestAllTypes> { private static readonly pb::MessageParser<NestedTestAllTypes> _parser = new pb::MessageParser<NestedTestAllTypes>(() => new NestedTestAllTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedTestAllTypes> Parser { get { return _parser; } } @@ -1758,6 +1789,7 @@ namespace Google.Protobuf.TestProtos { Child = other.child_ != null ? other.Child.Clone() : null; Payload = other.payload_ != null ? other.Payload.Clone() : null; repeatedChild_ = other.repeatedChild_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1813,7 +1845,7 @@ namespace Google.Protobuf.TestProtos { if (!object.Equals(Child, other.Child)) return false; if (!object.Equals(Payload, other.Payload)) return false; if(!repeatedChild_.Equals(other.repeatedChild_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1822,6 +1854,9 @@ namespace Google.Protobuf.TestProtos { if (child_ != null) hash ^= Child.GetHashCode(); if (payload_ != null) hash ^= Payload.GetHashCode(); hash ^= repeatedChild_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1841,6 +1876,9 @@ namespace Google.Protobuf.TestProtos { output.WriteMessage(Payload); } repeatedChild_.WriteTo(output, _repeated_repeatedChild_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1853,6 +1891,9 @@ namespace Google.Protobuf.TestProtos { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Payload); } size += repeatedChild_.CalculateSize(_repeated_repeatedChild_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1874,6 +1915,7 @@ namespace Google.Protobuf.TestProtos { Payload.MergeFrom(other.Payload); } repeatedChild_.Add(other.repeatedChild_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1882,7 +1924,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (child_ == null) { @@ -1910,6 +1952,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestDeprecatedFields : pb::IMessage<TestDeprecatedFields> { private static readonly pb::MessageParser<TestDeprecatedFields> _parser = new pb::MessageParser<TestDeprecatedFields>(() => new TestDeprecatedFields()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestDeprecatedFields> Parser { get { return _parser; } } @@ -1933,6 +1976,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestDeprecatedFields(TestDeprecatedFields other) : this() { deprecatedInt32_ = other.deprecatedInt32_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1966,13 +2010,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (DeprecatedInt32 != other.DeprecatedInt32) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (DeprecatedInt32 != 0) hash ^= DeprecatedInt32.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1987,6 +2034,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(DeprecatedInt32); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1995,6 +2045,9 @@ namespace Google.Protobuf.TestProtos { if (DeprecatedInt32 != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(DeprecatedInt32); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2006,6 +2059,7 @@ namespace Google.Protobuf.TestProtos { if (other.DeprecatedInt32 != 0) { DeprecatedInt32 = other.DeprecatedInt32; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2014,7 +2068,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { DeprecatedInt32 = input.ReadInt32(); @@ -2032,6 +2086,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class ForeignMessage : pb::IMessage<ForeignMessage> { private static readonly pb::MessageParser<ForeignMessage> _parser = new pb::MessageParser<ForeignMessage>(() => new ForeignMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<ForeignMessage> Parser { get { return _parser; } } @@ -2055,6 +2110,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public ForeignMessage(ForeignMessage other) : this() { c_ = other.c_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2087,13 +2143,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (C != other.C) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (C != 0) hash ^= C.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2108,6 +2167,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(C); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2116,6 +2178,9 @@ namespace Google.Protobuf.TestProtos { if (C != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(C); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2127,6 +2192,7 @@ namespace Google.Protobuf.TestProtos { if (other.C != 0) { C = other.C; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2135,7 +2201,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { C = input.ReadInt32(); @@ -2149,6 +2215,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestReservedFields : pb::IMessage<TestReservedFields> { private static readonly pb::MessageParser<TestReservedFields> _parser = new pb::MessageParser<TestReservedFields>(() => new TestReservedFields()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestReservedFields> Parser { get { return _parser; } } @@ -2171,6 +2238,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestReservedFields(TestReservedFields other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2191,12 +2259,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2207,11 +2278,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2220,6 +2297,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2228,7 +2306,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -2241,6 +2319,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestForeignNested : pb::IMessage<TestForeignNested> { private static readonly pb::MessageParser<TestForeignNested> _parser = new pb::MessageParser<TestForeignNested>(() => new TestForeignNested()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestForeignNested> Parser { get { return _parser; } } @@ -2264,6 +2343,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestForeignNested(TestForeignNested other) : this() { ForeignNested = other.foreignNested_ != null ? other.ForeignNested.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2296,13 +2376,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!object.Equals(ForeignNested, other.ForeignNested)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (foreignNested_ != null) hash ^= ForeignNested.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2317,6 +2400,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteMessage(ForeignNested); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2325,6 +2411,9 @@ namespace Google.Protobuf.TestProtos { if (foreignNested_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(ForeignNested); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2339,6 +2428,7 @@ namespace Google.Protobuf.TestProtos { } ForeignNested.MergeFrom(other.ForeignNested); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2347,7 +2437,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (foreignNested_ == null) { @@ -2367,6 +2457,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestReallyLargeTagNumber : pb::IMessage<TestReallyLargeTagNumber> { private static readonly pb::MessageParser<TestReallyLargeTagNumber> _parser = new pb::MessageParser<TestReallyLargeTagNumber>(() => new TestReallyLargeTagNumber()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestReallyLargeTagNumber> Parser { get { return _parser; } } @@ -2391,6 +2482,7 @@ namespace Google.Protobuf.TestProtos { public TestReallyLargeTagNumber(TestReallyLargeTagNumber other) : this() { a_ = other.a_; bb_ = other.bb_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2439,7 +2531,7 @@ namespace Google.Protobuf.TestProtos { } if (A != other.A) return false; if (Bb != other.Bb) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2447,6 +2539,9 @@ namespace Google.Protobuf.TestProtos { int hash = 1; if (A != 0) hash ^= A.GetHashCode(); if (Bb != 0) hash ^= Bb.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2465,6 +2560,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(248, 255, 255, 255, 7); output.WriteInt32(Bb); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2476,6 +2574,9 @@ namespace Google.Protobuf.TestProtos { if (Bb != 0) { size += 5 + pb::CodedOutputStream.ComputeInt32Size(Bb); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2490,6 +2591,7 @@ namespace Google.Protobuf.TestProtos { if (other.Bb != 0) { Bb = other.Bb; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2498,7 +2600,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { A = input.ReadInt32(); @@ -2516,6 +2618,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestRecursiveMessage : pb::IMessage<TestRecursiveMessage> { private static readonly pb::MessageParser<TestRecursiveMessage> _parser = new pb::MessageParser<TestRecursiveMessage>(() => new TestRecursiveMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestRecursiveMessage> Parser { get { return _parser; } } @@ -2540,6 +2643,7 @@ namespace Google.Protobuf.TestProtos { public TestRecursiveMessage(TestRecursiveMessage other) : this() { A = other.a_ != null ? other.A.Clone() : null; i_ = other.i_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2584,7 +2688,7 @@ namespace Google.Protobuf.TestProtos { } if (!object.Equals(A, other.A)) return false; if (I != other.I) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2592,6 +2696,9 @@ namespace Google.Protobuf.TestProtos { int hash = 1; if (a_ != null) hash ^= A.GetHashCode(); if (I != 0) hash ^= I.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2610,6 +2717,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(16); output.WriteInt32(I); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2621,6 +2731,9 @@ namespace Google.Protobuf.TestProtos { if (I != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(I); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2638,6 +2751,7 @@ namespace Google.Protobuf.TestProtos { if (other.I != 0) { I = other.I; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2646,7 +2760,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (a_ == null) { @@ -2670,6 +2784,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestMutualRecursionA : pb::IMessage<TestMutualRecursionA> { private static readonly pb::MessageParser<TestMutualRecursionA> _parser = new pb::MessageParser<TestMutualRecursionA>(() => new TestMutualRecursionA()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMutualRecursionA> Parser { get { return _parser; } } @@ -2693,6 +2808,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestMutualRecursionA(TestMutualRecursionA other) : this() { Bb = other.bb_ != null ? other.Bb.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2725,13 +2841,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (!object.Equals(Bb, other.Bb)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (bb_ != null) hash ^= Bb.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2746,6 +2865,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteMessage(Bb); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2754,6 +2876,9 @@ namespace Google.Protobuf.TestProtos { if (bb_ != null) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(Bb); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2768,6 +2893,7 @@ namespace Google.Protobuf.TestProtos { } Bb.MergeFrom(other.Bb); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2776,7 +2902,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (bb_ == null) { @@ -2793,6 +2919,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestMutualRecursionB : pb::IMessage<TestMutualRecursionB> { private static readonly pb::MessageParser<TestMutualRecursionB> _parser = new pb::MessageParser<TestMutualRecursionB>(() => new TestMutualRecursionB()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestMutualRecursionB> Parser { get { return _parser; } } @@ -2817,6 +2944,7 @@ namespace Google.Protobuf.TestProtos { public TestMutualRecursionB(TestMutualRecursionB other) : this() { A = other.a_ != null ? other.A.Clone() : null; optionalInt32_ = other.optionalInt32_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2861,7 +2989,7 @@ namespace Google.Protobuf.TestProtos { } if (!object.Equals(A, other.A)) return false; if (OptionalInt32 != other.OptionalInt32) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2869,6 +2997,9 @@ namespace Google.Protobuf.TestProtos { int hash = 1; if (a_ != null) hash ^= A.GetHashCode(); if (OptionalInt32 != 0) hash ^= OptionalInt32.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2887,6 +3018,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(16); output.WriteInt32(OptionalInt32); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2898,6 +3032,9 @@ namespace Google.Protobuf.TestProtos { if (OptionalInt32 != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(OptionalInt32); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2915,6 +3052,7 @@ namespace Google.Protobuf.TestProtos { if (other.OptionalInt32 != 0) { OptionalInt32 = other.OptionalInt32; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2923,7 +3061,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (a_ == null) { @@ -2944,6 +3082,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestEnumAllowAlias : pb::IMessage<TestEnumAllowAlias> { private static readonly pb::MessageParser<TestEnumAllowAlias> _parser = new pb::MessageParser<TestEnumAllowAlias>(() => new TestEnumAllowAlias()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestEnumAllowAlias> Parser { get { return _parser; } } @@ -2967,6 +3106,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestEnumAllowAlias(TestEnumAllowAlias other) : this() { value_ = other.value_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2999,13 +3139,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Value != other.Value) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Value != 0) hash ^= Value.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3020,6 +3163,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteEnum((int) Value); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3028,6 +3174,9 @@ namespace Google.Protobuf.TestProtos { if (Value != 0) { size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) Value); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3039,6 +3188,7 @@ namespace Google.Protobuf.TestProtos { if (other.Value != 0) { Value = other.Value; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3047,7 +3197,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { value_ = (global::Google.Protobuf.TestProtos.TestEnumWithDupValue) input.ReadEnum(); @@ -3065,6 +3215,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestCamelCaseFieldNames : pb::IMessage<TestCamelCaseFieldNames> { private static readonly pb::MessageParser<TestCamelCaseFieldNames> _parser = new pb::MessageParser<TestCamelCaseFieldNames>(() => new TestCamelCaseFieldNames()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestCamelCaseFieldNames> Parser { get { return _parser; } } @@ -3095,6 +3246,7 @@ namespace Google.Protobuf.TestProtos { repeatedStringField_ = other.repeatedStringField_.Clone(); repeatedEnumField_ = other.repeatedEnumField_.Clone(); repeatedMessageField_ = other.repeatedMessageField_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3207,7 +3359,7 @@ namespace Google.Protobuf.TestProtos { if(!repeatedStringField_.Equals(other.repeatedStringField_)) return false; if(!repeatedEnumField_.Equals(other.repeatedEnumField_)) return false; if(!repeatedMessageField_.Equals(other.repeatedMessageField_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3221,6 +3373,9 @@ namespace Google.Protobuf.TestProtos { hash ^= repeatedStringField_.GetHashCode(); hash ^= repeatedEnumField_.GetHashCode(); hash ^= repeatedMessageField_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3251,6 +3406,9 @@ namespace Google.Protobuf.TestProtos { repeatedStringField_.WriteTo(output, _repeated_repeatedStringField_codec); repeatedEnumField_.WriteTo(output, _repeated_repeatedEnumField_codec); repeatedMessageField_.WriteTo(output, _repeated_repeatedMessageField_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3272,6 +3430,9 @@ namespace Google.Protobuf.TestProtos { size += repeatedStringField_.CalculateSize(_repeated_repeatedStringField_codec); size += repeatedEnumField_.CalculateSize(_repeated_repeatedEnumField_codec); size += repeatedMessageField_.CalculateSize(_repeated_repeatedMessageField_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3299,6 +3460,7 @@ namespace Google.Protobuf.TestProtos { repeatedStringField_.Add(other.repeatedStringField_); repeatedEnumField_.Add(other.repeatedEnumField_); repeatedMessageField_.Add(other.repeatedMessageField_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3307,7 +3469,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { PrimitiveField = input.ReadInt32(); @@ -3358,6 +3520,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestFieldOrderings : pb::IMessage<TestFieldOrderings> { private static readonly pb::MessageParser<TestFieldOrderings> _parser = new pb::MessageParser<TestFieldOrderings>(() => new TestFieldOrderings()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestFieldOrderings> Parser { get { return _parser; } } @@ -3384,6 +3547,7 @@ namespace Google.Protobuf.TestProtos { myInt_ = other.myInt_; myFloat_ = other.myFloat_; SingleNestedMessage = other.singleNestedMessage_ != null ? other.SingleNestedMessage.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3450,9 +3614,9 @@ namespace Google.Protobuf.TestProtos { } if (MyString != other.MyString) return false; if (MyInt != other.MyInt) return false; - if (MyFloat != other.MyFloat) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.Equals(MyFloat, other.MyFloat)) return false; if (!object.Equals(SingleNestedMessage, other.SingleNestedMessage)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3460,8 +3624,11 @@ namespace Google.Protobuf.TestProtos { int hash = 1; if (MyString.Length != 0) hash ^= MyString.GetHashCode(); if (MyInt != 0L) hash ^= MyInt.GetHashCode(); - if (MyFloat != 0F) hash ^= MyFloat.GetHashCode(); + if (MyFloat != 0F) hash ^= pbc::ProtobufEqualityComparers.BitwiseSingleEqualityComparer.GetHashCode(MyFloat); if (singleNestedMessage_ != null) hash ^= SingleNestedMessage.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3488,6 +3655,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(194, 12); output.WriteMessage(SingleNestedMessage); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3505,6 +3675,9 @@ namespace Google.Protobuf.TestProtos { if (singleNestedMessage_ != null) { size += 2 + pb::CodedOutputStream.ComputeMessageSize(SingleNestedMessage); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3528,6 +3701,7 @@ namespace Google.Protobuf.TestProtos { } SingleNestedMessage.MergeFrom(other.SingleNestedMessage); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3536,7 +3710,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { MyInt = input.ReadInt64(); @@ -3567,6 +3741,7 @@ namespace Google.Protobuf.TestProtos { public static partial class Types { public sealed partial class NestedMessage : pb::IMessage<NestedMessage> { private static readonly pb::MessageParser<NestedMessage> _parser = new pb::MessageParser<NestedMessage>(() => new NestedMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<NestedMessage> Parser { get { return _parser; } } @@ -3591,6 +3766,7 @@ namespace Google.Protobuf.TestProtos { public NestedMessage(NestedMessage other) : this() { oo_ = other.oo_; bb_ = other.bb_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3640,7 +3816,7 @@ namespace Google.Protobuf.TestProtos { } if (Oo != other.Oo) return false; if (Bb != other.Bb) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3648,6 +3824,9 @@ namespace Google.Protobuf.TestProtos { int hash = 1; if (Oo != 0L) hash ^= Oo.GetHashCode(); if (Bb != 0) hash ^= Bb.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3666,6 +3845,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(16); output.WriteInt64(Oo); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3677,6 +3859,9 @@ namespace Google.Protobuf.TestProtos { if (Bb != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Bb); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3691,6 +3876,7 @@ namespace Google.Protobuf.TestProtos { if (other.Bb != 0) { Bb = other.Bb; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3699,7 +3885,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Bb = input.ReadInt32(); @@ -3722,6 +3908,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class SparseEnumMessage : pb::IMessage<SparseEnumMessage> { private static readonly pb::MessageParser<SparseEnumMessage> _parser = new pb::MessageParser<SparseEnumMessage>(() => new SparseEnumMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<SparseEnumMessage> Parser { get { return _parser; } } @@ -3745,6 +3932,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public SparseEnumMessage(SparseEnumMessage other) : this() { sparseEnum_ = other.sparseEnum_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3777,13 +3965,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (SparseEnum != other.SparseEnum) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (SparseEnum != 0) hash ^= SparseEnum.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3798,6 +3989,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteEnum((int) SparseEnum); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3806,6 +4000,9 @@ namespace Google.Protobuf.TestProtos { if (SparseEnum != 0) { size += 1 + pb::CodedOutputStream.ComputeEnumSize((int) SparseEnum); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3817,6 +4014,7 @@ namespace Google.Protobuf.TestProtos { if (other.SparseEnum != 0) { SparseEnum = other.SparseEnum; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3825,7 +4023,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { sparseEnum_ = (global::Google.Protobuf.TestProtos.TestSparseEnum) input.ReadEnum(); @@ -3842,6 +4040,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class OneString : pb::IMessage<OneString> { private static readonly pb::MessageParser<OneString> _parser = new pb::MessageParser<OneString>(() => new OneString()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<OneString> Parser { get { return _parser; } } @@ -3865,6 +4064,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public OneString(OneString other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3897,13 +4097,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data.Length != 0) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -3918,6 +4121,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteString(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3926,6 +4132,9 @@ namespace Google.Protobuf.TestProtos { if (Data.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -3937,6 +4146,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data.Length != 0) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -3945,7 +4155,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Data = input.ReadString(); @@ -3959,6 +4169,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class MoreString : pb::IMessage<MoreString> { private static readonly pb::MessageParser<MoreString> _parser = new pb::MessageParser<MoreString>(() => new MoreString()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<MoreString> Parser { get { return _parser; } } @@ -3982,6 +4193,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public MoreString(MoreString other) : this() { data_ = other.data_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4013,13 +4225,16 @@ namespace Google.Protobuf.TestProtos { return true; } if(!data_.Equals(other.data_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; hash ^= data_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4031,12 +4246,18 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { data_.WriteTo(output, _repeated_data_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; size += data_.CalculateSize(_repeated_data_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4046,6 +4267,7 @@ namespace Google.Protobuf.TestProtos { return; } data_.Add(other.data_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4054,7 +4276,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { data_.AddEntriesFrom(input, _repeated_data_codec); @@ -4068,6 +4290,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class OneBytes : pb::IMessage<OneBytes> { private static readonly pb::MessageParser<OneBytes> _parser = new pb::MessageParser<OneBytes>(() => new OneBytes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<OneBytes> Parser { get { return _parser; } } @@ -4091,6 +4314,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public OneBytes(OneBytes other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4123,13 +4347,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data.Length != 0) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4144,6 +4371,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteBytes(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4152,6 +4382,9 @@ namespace Google.Protobuf.TestProtos { if (Data.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeBytesSize(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4163,6 +4396,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data.Length != 0) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4171,7 +4405,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Data = input.ReadBytes(); @@ -4185,6 +4419,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class MoreBytes : pb::IMessage<MoreBytes> { private static readonly pb::MessageParser<MoreBytes> _parser = new pb::MessageParser<MoreBytes>(() => new MoreBytes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<MoreBytes> Parser { get { return _parser; } } @@ -4208,6 +4443,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public MoreBytes(MoreBytes other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4240,13 +4476,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data.Length != 0) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4261,6 +4500,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteBytes(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4269,6 +4511,9 @@ namespace Google.Protobuf.TestProtos { if (Data.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeBytesSize(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4280,6 +4525,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data.Length != 0) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4288,7 +4534,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { Data = input.ReadBytes(); @@ -4305,6 +4551,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class Int32Message : pb::IMessage<Int32Message> { private static readonly pb::MessageParser<Int32Message> _parser = new pb::MessageParser<Int32Message>(() => new Int32Message()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Int32Message> Parser { get { return _parser; } } @@ -4328,6 +4575,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Int32Message(Int32Message other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4360,13 +4608,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data != 0) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4381,6 +4632,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt32(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4389,6 +4643,9 @@ namespace Google.Protobuf.TestProtos { if (Data != 0) { size += 1 + pb::CodedOutputStream.ComputeInt32Size(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4400,6 +4657,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data != 0) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4408,7 +4666,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Data = input.ReadInt32(); @@ -4422,6 +4680,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class Uint32Message : pb::IMessage<Uint32Message> { private static readonly pb::MessageParser<Uint32Message> _parser = new pb::MessageParser<Uint32Message>(() => new Uint32Message()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Uint32Message> Parser { get { return _parser; } } @@ -4445,6 +4704,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Uint32Message(Uint32Message other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4477,13 +4737,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data != 0) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4498,6 +4761,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteUInt32(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4506,6 +4772,9 @@ namespace Google.Protobuf.TestProtos { if (Data != 0) { size += 1 + pb::CodedOutputStream.ComputeUInt32Size(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4517,6 +4786,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data != 0) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4525,7 +4795,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Data = input.ReadUInt32(); @@ -4539,6 +4809,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class Int64Message : pb::IMessage<Int64Message> { private static readonly pb::MessageParser<Int64Message> _parser = new pb::MessageParser<Int64Message>(() => new Int64Message()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Int64Message> Parser { get { return _parser; } } @@ -4562,6 +4833,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Int64Message(Int64Message other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4594,13 +4866,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data != 0L) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4615,6 +4890,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteInt64(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4623,6 +4901,9 @@ namespace Google.Protobuf.TestProtos { if (Data != 0L) { size += 1 + pb::CodedOutputStream.ComputeInt64Size(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4634,6 +4915,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data != 0L) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4642,7 +4924,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Data = input.ReadInt64(); @@ -4656,6 +4938,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class Uint64Message : pb::IMessage<Uint64Message> { private static readonly pb::MessageParser<Uint64Message> _parser = new pb::MessageParser<Uint64Message>(() => new Uint64Message()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<Uint64Message> Parser { get { return _parser; } } @@ -4679,6 +4962,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public Uint64Message(Uint64Message other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4711,13 +4995,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data != 0UL) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4732,6 +5019,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteUInt64(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4740,6 +5030,9 @@ namespace Google.Protobuf.TestProtos { if (Data != 0UL) { size += 1 + pb::CodedOutputStream.ComputeUInt64Size(Data); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4751,6 +5044,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data != 0UL) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4759,7 +5053,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Data = input.ReadUInt64(); @@ -4773,6 +5067,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class BoolMessage : pb::IMessage<BoolMessage> { private static readonly pb::MessageParser<BoolMessage> _parser = new pb::MessageParser<BoolMessage>(() => new BoolMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<BoolMessage> Parser { get { return _parser; } } @@ -4796,6 +5091,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public BoolMessage(BoolMessage other) : this() { data_ = other.data_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4828,13 +5124,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (Data != other.Data) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (Data != false) hash ^= Data.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -4849,6 +5148,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(8); output.WriteBool(Data); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4857,6 +5159,9 @@ namespace Google.Protobuf.TestProtos { if (Data != false) { size += 1 + 1; } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -4868,6 +5173,7 @@ namespace Google.Protobuf.TestProtos { if (other.Data != false) { Data = other.Data; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -4876,7 +5182,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { Data = input.ReadBool(); @@ -4893,6 +5199,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestOneof : pb::IMessage<TestOneof> { private static readonly pb::MessageParser<TestOneof> _parser = new pb::MessageParser<TestOneof>(() => new TestOneof()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestOneof> Parser { get { return _parser; } } @@ -4927,6 +5234,7 @@ namespace Google.Protobuf.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5004,7 +5312,7 @@ namespace Google.Protobuf.TestProtos { if (FooString != other.FooString) return false; if (!object.Equals(FooMessage, other.FooMessage)) return false; if (FooCase != other.FooCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5014,6 +5322,9 @@ namespace Google.Protobuf.TestProtos { if (fooCase_ == FooOneofCase.FooString) hash ^= FooString.GetHashCode(); if (fooCase_ == FooOneofCase.FooMessage) hash ^= FooMessage.GetHashCode(); hash ^= (int) fooCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -5036,6 +5347,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(26); output.WriteMessage(FooMessage); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5050,6 +5364,9 @@ namespace Google.Protobuf.TestProtos { if (fooCase_ == FooOneofCase.FooMessage) { size += 1 + pb::CodedOutputStream.ComputeMessageSize(FooMessage); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -5066,10 +5383,14 @@ namespace Google.Protobuf.TestProtos { FooString = other.FooString; break; case FooOneofCase.FooMessage: - FooMessage = other.FooMessage; + if (FooMessage == null) { + FooMessage = new global::Google.Protobuf.TestProtos.TestAllTypes(); + } + FooMessage.MergeFrom(other.FooMessage); break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5078,7 +5399,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 8: { FooInt = input.ReadInt32(); @@ -5105,6 +5426,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestPackedTypes : pb::IMessage<TestPackedTypes> { private static readonly pb::MessageParser<TestPackedTypes> _parser = new pb::MessageParser<TestPackedTypes>(() => new TestPackedTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestPackedTypes> Parser { get { return _parser; } } @@ -5141,6 +5463,7 @@ namespace Google.Protobuf.TestProtos { packedDouble_ = other.packedDouble_.Clone(); packedBool_ = other.packedBool_.Clone(); packedEnum_ = other.packedEnum_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5315,7 +5638,7 @@ namespace Google.Protobuf.TestProtos { if(!packedDouble_.Equals(other.packedDouble_)) return false; if(!packedBool_.Equals(other.packedBool_)) return false; if(!packedEnum_.Equals(other.packedEnum_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5335,6 +5658,9 @@ namespace Google.Protobuf.TestProtos { hash ^= packedDouble_.GetHashCode(); hash ^= packedBool_.GetHashCode(); hash ^= packedEnum_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -5359,6 +5685,9 @@ namespace Google.Protobuf.TestProtos { packedDouble_.WriteTo(output, _repeated_packedDouble_codec); packedBool_.WriteTo(output, _repeated_packedBool_codec); packedEnum_.WriteTo(output, _repeated_packedEnum_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5378,6 +5707,9 @@ namespace Google.Protobuf.TestProtos { size += packedDouble_.CalculateSize(_repeated_packedDouble_codec); size += packedBool_.CalculateSize(_repeated_packedBool_codec); size += packedEnum_.CalculateSize(_repeated_packedEnum_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -5400,6 +5732,7 @@ namespace Google.Protobuf.TestProtos { packedDouble_.Add(other.packedDouble_); packedBool_.Add(other.packedBool_); packedEnum_.Add(other.packedEnum_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5408,7 +5741,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 722: case 720: { @@ -5492,6 +5825,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestUnpackedTypes : pb::IMessage<TestUnpackedTypes> { private static readonly pb::MessageParser<TestUnpackedTypes> _parser = new pb::MessageParser<TestUnpackedTypes>(() => new TestUnpackedTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestUnpackedTypes> Parser { get { return _parser; } } @@ -5528,6 +5862,7 @@ namespace Google.Protobuf.TestProtos { unpackedDouble_ = other.unpackedDouble_.Clone(); unpackedBool_ = other.unpackedBool_.Clone(); unpackedEnum_ = other.unpackedEnum_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5702,7 +6037,7 @@ namespace Google.Protobuf.TestProtos { if(!unpackedDouble_.Equals(other.unpackedDouble_)) return false; if(!unpackedBool_.Equals(other.unpackedBool_)) return false; if(!unpackedEnum_.Equals(other.unpackedEnum_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5722,6 +6057,9 @@ namespace Google.Protobuf.TestProtos { hash ^= unpackedDouble_.GetHashCode(); hash ^= unpackedBool_.GetHashCode(); hash ^= unpackedEnum_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -5746,6 +6084,9 @@ namespace Google.Protobuf.TestProtos { unpackedDouble_.WriteTo(output, _repeated_unpackedDouble_codec); unpackedBool_.WriteTo(output, _repeated_unpackedBool_codec); unpackedEnum_.WriteTo(output, _repeated_unpackedEnum_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5765,6 +6106,9 @@ namespace Google.Protobuf.TestProtos { size += unpackedDouble_.CalculateSize(_repeated_unpackedDouble_codec); size += unpackedBool_.CalculateSize(_repeated_unpackedBool_codec); size += unpackedEnum_.CalculateSize(_repeated_unpackedEnum_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -5787,6 +6131,7 @@ namespace Google.Protobuf.TestProtos { unpackedDouble_.Add(other.unpackedDouble_); unpackedBool_.Add(other.unpackedBool_); unpackedEnum_.Add(other.unpackedEnum_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -5795,7 +6140,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 722: case 720: { @@ -5875,6 +6220,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestRepeatedScalarDifferentTagSizes : pb::IMessage<TestRepeatedScalarDifferentTagSizes> { private static readonly pb::MessageParser<TestRepeatedScalarDifferentTagSizes> _parser = new pb::MessageParser<TestRepeatedScalarDifferentTagSizes>(() => new TestRepeatedScalarDifferentTagSizes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestRepeatedScalarDifferentTagSizes> Parser { get { return _parser; } } @@ -5903,6 +6249,7 @@ namespace Google.Protobuf.TestProtos { repeatedInt64_ = other.repeatedInt64_.Clone(); repeatedFloat_ = other.repeatedFloat_.Clone(); repeatedUint64_ = other.repeatedUint64_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6003,7 +6350,7 @@ namespace Google.Protobuf.TestProtos { if(!repeatedInt64_.Equals(other.repeatedInt64_)) return false; if(!repeatedFloat_.Equals(other.repeatedFloat_)) return false; if(!repeatedUint64_.Equals(other.repeatedUint64_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6015,6 +6362,9 @@ namespace Google.Protobuf.TestProtos { hash ^= repeatedInt64_.GetHashCode(); hash ^= repeatedFloat_.GetHashCode(); hash ^= repeatedUint64_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6031,6 +6381,9 @@ namespace Google.Protobuf.TestProtos { repeatedInt64_.WriteTo(output, _repeated_repeatedInt64_codec); repeatedFloat_.WriteTo(output, _repeated_repeatedFloat_codec); repeatedUint64_.WriteTo(output, _repeated_repeatedUint64_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6042,6 +6395,9 @@ namespace Google.Protobuf.TestProtos { size += repeatedInt64_.CalculateSize(_repeated_repeatedInt64_codec); size += repeatedFloat_.CalculateSize(_repeated_repeatedFloat_codec); size += repeatedUint64_.CalculateSize(_repeated_repeatedUint64_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6056,6 +6412,7 @@ namespace Google.Protobuf.TestProtos { repeatedInt64_.Add(other.repeatedInt64_); repeatedFloat_.Add(other.repeatedFloat_); repeatedUint64_.Add(other.repeatedUint64_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6064,7 +6421,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 98: case 101: { @@ -6104,6 +6461,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class TestCommentInjectionMessage : pb::IMessage<TestCommentInjectionMessage> { private static readonly pb::MessageParser<TestCommentInjectionMessage> _parser = new pb::MessageParser<TestCommentInjectionMessage>(() => new TestCommentInjectionMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestCommentInjectionMessage> Parser { get { return _parser; } } @@ -6127,6 +6485,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public TestCommentInjectionMessage(TestCommentInjectionMessage other) : this() { a_ = other.a_; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6162,13 +6521,16 @@ namespace Google.Protobuf.TestProtos { return true; } if (A != other.A) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; if (A.Length != 0) hash ^= A.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6183,6 +6545,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(10); output.WriteString(A); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6191,6 +6556,9 @@ namespace Google.Protobuf.TestProtos { if (A.Length != 0) { size += 1 + pb::CodedOutputStream.ComputeStringSize(A); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6202,6 +6570,7 @@ namespace Google.Protobuf.TestProtos { if (other.A.Length != 0) { A = other.A; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6210,7 +6579,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { A = input.ReadString(); @@ -6227,6 +6596,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class FooRequest : pb::IMessage<FooRequest> { private static readonly pb::MessageParser<FooRequest> _parser = new pb::MessageParser<FooRequest>(() => new FooRequest()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<FooRequest> Parser { get { return _parser; } } @@ -6249,6 +6619,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public FooRequest(FooRequest other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6269,12 +6640,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6285,11 +6659,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6298,6 +6678,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6306,7 +6687,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -6316,6 +6697,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class FooResponse : pb::IMessage<FooResponse> { private static readonly pb::MessageParser<FooResponse> _parser = new pb::MessageParser<FooResponse>(() => new FooResponse()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<FooResponse> Parser { get { return _parser; } } @@ -6338,6 +6720,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public FooResponse(FooResponse other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6358,12 +6741,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6374,11 +6760,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6387,6 +6779,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6395,7 +6788,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -6405,6 +6798,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class FooClientMessage : pb::IMessage<FooClientMessage> { private static readonly pb::MessageParser<FooClientMessage> _parser = new pb::MessageParser<FooClientMessage>(() => new FooClientMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<FooClientMessage> Parser { get { return _parser; } } @@ -6427,6 +6821,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public FooClientMessage(FooClientMessage other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6447,12 +6842,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6463,11 +6861,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6476,6 +6880,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6484,7 +6889,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -6494,6 +6899,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class FooServerMessage : pb::IMessage<FooServerMessage> { private static readonly pb::MessageParser<FooServerMessage> _parser = new pb::MessageParser<FooServerMessage>(() => new FooServerMessage()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<FooServerMessage> Parser { get { return _parser; } } @@ -6516,6 +6922,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public FooServerMessage(FooServerMessage other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6536,12 +6943,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6552,11 +6962,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6565,6 +6981,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6573,7 +6990,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -6583,6 +7000,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class BarRequest : pb::IMessage<BarRequest> { private static readonly pb::MessageParser<BarRequest> _parser = new pb::MessageParser<BarRequest>(() => new BarRequest()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<BarRequest> Parser { get { return _parser; } } @@ -6605,6 +7023,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public BarRequest(BarRequest other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6625,12 +7044,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6641,11 +7063,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6654,6 +7082,7 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6662,7 +7091,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } @@ -6672,6 +7101,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class BarResponse : pb::IMessage<BarResponse> { private static readonly pb::MessageParser<BarResponse> _parser = new pb::MessageParser<BarResponse>(() => new BarResponse()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<BarResponse> Parser { get { return _parser; } } @@ -6694,6 +7124,7 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public BarResponse(BarResponse other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6714,12 +7145,15 @@ namespace Google.Protobuf.TestProtos { if (ReferenceEquals(other, this)) { return true; } - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public override int GetHashCode() { int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -6730,11 +7164,17 @@ namespace Google.Protobuf.TestProtos { [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public int CalculateSize() { int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -6743,6 +7183,108 @@ namespace Google.Protobuf.TestProtos { if (other == null) { return; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(pb::CodedInputStream input) { + uint tag; + while ((tag = input.ReadTag()) != 0) { + switch(tag) { + default: + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); + break; + } + } + } + + } + + public sealed partial class TestEmptyMessage : pb::IMessage<TestEmptyMessage> { + private static readonly pb::MessageParser<TestEmptyMessage> _parser = new pb::MessageParser<TestEmptyMessage>(() => new TestEmptyMessage()); + private pb::UnknownFieldSet _unknownFields; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pb::MessageParser<TestEmptyMessage> Parser { get { return _parser; } } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public static pbr::MessageDescriptor Descriptor { + get { return global::Google.Protobuf.TestProtos.UnittestProto3Reflection.Descriptor.MessageTypes[34]; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + pbr::MessageDescriptor pb::IMessage.Descriptor { + get { return Descriptor; } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TestEmptyMessage() { + OnConstruction(); + } + + partial void OnConstruction(); + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TestEmptyMessage(TestEmptyMessage other) : this() { + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public TestEmptyMessage Clone() { + return new TestEmptyMessage(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override bool Equals(object other) { + return Equals(other as TestEmptyMessage); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public bool Equals(TestEmptyMessage other) { + if (ReferenceEquals(other, null)) { + return false; + } + if (ReferenceEquals(other, this)) { + return true; + } + return Equals(_unknownFields, other._unknownFields); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override int GetHashCode() { + int hash = 1; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } + return hash; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public override string ToString() { + return pb::JsonFormatter.ToDiagnosticString(this); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void WriteTo(pb::CodedOutputStream output) { + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public int CalculateSize() { + int size = 0; + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } + return size; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + public void MergeFrom(TestEmptyMessage other) { + if (other == null) { + return; + } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -6751,7 +7293,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; } } diff --git a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestWellKnownTypes.cs b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestWellKnownTypes.cs index 2c7f0e0e..2e1d2bd6 100644 --- a/csharp/src/Google.Protobuf.Test/TestProtos/UnittestWellKnownTypes.cs +++ b/csharp/src/Google.Protobuf.Test/TestProtos/UnittestWellKnownTypes.cs @@ -1,5 +1,7 @@ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/protobuf/unittest_well_known_types.proto +// <auto-generated> +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/protobuf/unittest_well_known_types.proto +// </auto-generated> #pragma warning disable 1591, 0612, 3021 #region Designer generated code @@ -179,6 +181,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class TestWellKnownTypes : pb::IMessage<TestWellKnownTypes> { private static readonly pb::MessageParser<TestWellKnownTypes> _parser = new pb::MessageParser<TestWellKnownTypes>(() => new TestWellKnownTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<TestWellKnownTypes> Parser { get { return _parser; } } @@ -220,6 +223,7 @@ namespace Google.Protobuf.TestProtos { StringField = other.StringField; BytesField = other.BytesField; ValueField = other.valueField_ != null ? other.ValueField.Clone() : null; + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -470,8 +474,8 @@ namespace Google.Protobuf.TestProtos { if (!object.Equals(StructField, other.StructField)) return false; if (!object.Equals(TimestampField, other.TimestampField)) return false; if (!object.Equals(TypeField, other.TypeField)) return false; - if (DoubleField != other.DoubleField) return false; - if (FloatField != other.FloatField) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(DoubleField, other.DoubleField)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.Equals(FloatField, other.FloatField)) return false; if (Int64Field != other.Int64Field) return false; if (Uint64Field != other.Uint64Field) return false; if (Int32Field != other.Int32Field) return false; @@ -480,7 +484,7 @@ namespace Google.Protobuf.TestProtos { if (StringField != other.StringField) return false; if (BytesField != other.BytesField) return false; if (!object.Equals(ValueField, other.ValueField)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -495,8 +499,8 @@ namespace Google.Protobuf.TestProtos { if (structField_ != null) hash ^= StructField.GetHashCode(); if (timestampField_ != null) hash ^= TimestampField.GetHashCode(); if (typeField_ != null) hash ^= TypeField.GetHashCode(); - if (doubleField_ != null) hash ^= DoubleField.GetHashCode(); - if (floatField_ != null) hash ^= FloatField.GetHashCode(); + if (doubleField_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(DoubleField); + if (floatField_ != null) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.GetHashCode(FloatField); if (int64Field_ != null) hash ^= Int64Field.GetHashCode(); if (uint64Field_ != null) hash ^= Uint64Field.GetHashCode(); if (int32Field_ != null) hash ^= Int32Field.GetHashCode(); @@ -505,6 +509,9 @@ namespace Google.Protobuf.TestProtos { if (stringField_ != null) hash ^= StringField.GetHashCode(); if (bytesField_ != null) hash ^= BytesField.GetHashCode(); if (valueField_ != null) hash ^= ValueField.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -582,6 +589,9 @@ namespace Google.Protobuf.TestProtos { output.WriteRawTag(154, 1); output.WriteMessage(ValueField); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -644,6 +654,9 @@ namespace Google.Protobuf.TestProtos { if (valueField_ != null) { size += 2 + pb::CodedOutputStream.ComputeMessageSize(ValueField); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -757,6 +770,7 @@ namespace Google.Protobuf.TestProtos { } ValueField.MergeFrom(other.ValueField); } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -765,7 +779,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { if (anyField_ == null) { @@ -911,6 +925,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class RepeatedWellKnownTypes : pb::IMessage<RepeatedWellKnownTypes> { private static readonly pb::MessageParser<RepeatedWellKnownTypes> _parser = new pb::MessageParser<RepeatedWellKnownTypes>(() => new RepeatedWellKnownTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<RepeatedWellKnownTypes> Parser { get { return _parser; } } @@ -951,6 +966,7 @@ namespace Google.Protobuf.TestProtos { boolField_ = other.boolField_.Clone(); stringField_ = other.stringField_.Clone(); bytesField_ = other.bytesField_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1172,7 +1188,7 @@ namespace Google.Protobuf.TestProtos { if(!boolField_.Equals(other.boolField_)) return false; if(!stringField_.Equals(other.stringField_)) return false; if(!bytesField_.Equals(other.bytesField_)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1196,6 +1212,9 @@ namespace Google.Protobuf.TestProtos { hash ^= boolField_.GetHashCode(); hash ^= stringField_.GetHashCode(); hash ^= bytesField_.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1224,6 +1243,9 @@ namespace Google.Protobuf.TestProtos { boolField_.WriteTo(output, _repeated_boolField_codec); stringField_.WriteTo(output, _repeated_stringField_codec); bytesField_.WriteTo(output, _repeated_bytesField_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1247,6 +1269,9 @@ namespace Google.Protobuf.TestProtos { size += boolField_.CalculateSize(_repeated_boolField_codec); size += stringField_.CalculateSize(_repeated_stringField_codec); size += bytesField_.CalculateSize(_repeated_bytesField_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1273,6 +1298,7 @@ namespace Google.Protobuf.TestProtos { boolField_.Add(other.boolField_); stringField_.Add(other.stringField_); bytesField_.Add(other.bytesField_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1281,7 +1307,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { anyField_.AddEntriesFrom(input, _repeated_anyField_codec); @@ -1363,6 +1389,7 @@ namespace Google.Protobuf.TestProtos { public sealed partial class OneofWellKnownTypes : pb::IMessage<OneofWellKnownTypes> { private static readonly pb::MessageParser<OneofWellKnownTypes> _parser = new pb::MessageParser<OneofWellKnownTypes>(() => new OneofWellKnownTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<OneofWellKnownTypes> Parser { get { return _parser; } } @@ -1442,6 +1469,7 @@ namespace Google.Protobuf.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1713,8 +1741,8 @@ namespace Google.Protobuf.TestProtos { if (!object.Equals(StructField, other.StructField)) return false; if (!object.Equals(TimestampField, other.TimestampField)) return false; if (!object.Equals(TypeField, other.TypeField)) return false; - if (DoubleField != other.DoubleField) return false; - if (FloatField != other.FloatField) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.Equals(DoubleField, other.DoubleField)) return false; + if (!pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.Equals(FloatField, other.FloatField)) return false; if (Int64Field != other.Int64Field) return false; if (Uint64Field != other.Uint64Field) return false; if (Int32Field != other.Int32Field) return false; @@ -1723,7 +1751,7 @@ namespace Google.Protobuf.TestProtos { if (StringField != other.StringField) return false; if (BytesField != other.BytesField) return false; if (OneofFieldCase != other.OneofFieldCase) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1738,8 +1766,8 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.StructField) hash ^= StructField.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.TimestampField) hash ^= TimestampField.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.TypeField) hash ^= TypeField.GetHashCode(); - if (oneofFieldCase_ == OneofFieldOneofCase.DoubleField) hash ^= DoubleField.GetHashCode(); - if (oneofFieldCase_ == OneofFieldOneofCase.FloatField) hash ^= FloatField.GetHashCode(); + if (oneofFieldCase_ == OneofFieldOneofCase.DoubleField) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableDoubleEqualityComparer.GetHashCode(DoubleField); + if (oneofFieldCase_ == OneofFieldOneofCase.FloatField) hash ^= pbc::ProtobufEqualityComparers.BitwiseNullableSingleEqualityComparer.GetHashCode(FloatField); if (oneofFieldCase_ == OneofFieldOneofCase.Int64Field) hash ^= Int64Field.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.Uint64Field) hash ^= Uint64Field.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.Int32Field) hash ^= Int32Field.GetHashCode(); @@ -1748,6 +1776,9 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.StringField) hash ^= StringField.GetHashCode(); if (oneofFieldCase_ == OneofFieldOneofCase.BytesField) hash ^= BytesField.GetHashCode(); hash ^= (int) oneofFieldCase_; + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -1821,6 +1852,9 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.BytesField) { _oneof_bytesField_codec.WriteTagAndValue(output, (pb::ByteString) oneofField_); } + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1880,6 +1914,9 @@ namespace Google.Protobuf.TestProtos { if (oneofFieldCase_ == OneofFieldOneofCase.BytesField) { size += _oneof_bytesField_codec.CalculateSizeWithTag(BytesField); } + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -1890,31 +1927,58 @@ namespace Google.Protobuf.TestProtos { } switch (other.OneofFieldCase) { case OneofFieldOneofCase.AnyField: - AnyField = other.AnyField; + if (AnyField == null) { + AnyField = new global::Google.Protobuf.WellKnownTypes.Any(); + } + AnyField.MergeFrom(other.AnyField); break; case OneofFieldOneofCase.ApiField: - ApiField = other.ApiField; + if (ApiField == null) { + ApiField = new global::Google.Protobuf.WellKnownTypes.Api(); + } + ApiField.MergeFrom(other.ApiField); break; case OneofFieldOneofCase.DurationField: - DurationField = other.DurationField; + if (DurationField == null) { + DurationField = new global::Google.Protobuf.WellKnownTypes.Duration(); + } + DurationField.MergeFrom(other.DurationField); break; case OneofFieldOneofCase.EmptyField: - EmptyField = other.EmptyField; + if (EmptyField == null) { + EmptyField = new global::Google.Protobuf.WellKnownTypes.Empty(); + } + EmptyField.MergeFrom(other.EmptyField); break; case OneofFieldOneofCase.FieldMaskField: - FieldMaskField = other.FieldMaskField; + if (FieldMaskField == null) { + FieldMaskField = new global::Google.Protobuf.WellKnownTypes.FieldMask(); + } + FieldMaskField.MergeFrom(other.FieldMaskField); break; case OneofFieldOneofCase.SourceContextField: - SourceContextField = other.SourceContextField; + if (SourceContextField == null) { + SourceContextField = new global::Google.Protobuf.WellKnownTypes.SourceContext(); + } + SourceContextField.MergeFrom(other.SourceContextField); break; case OneofFieldOneofCase.StructField: - StructField = other.StructField; + if (StructField == null) { + StructField = new global::Google.Protobuf.WellKnownTypes.Struct(); + } + StructField.MergeFrom(other.StructField); break; case OneofFieldOneofCase.TimestampField: - TimestampField = other.TimestampField; + if (TimestampField == null) { + TimestampField = new global::Google.Protobuf.WellKnownTypes.Timestamp(); + } + TimestampField.MergeFrom(other.TimestampField); break; case OneofFieldOneofCase.TypeField: - TypeField = other.TypeField; + if (TypeField == null) { + TypeField = new global::Google.Protobuf.WellKnownTypes.Type(); + } + TypeField.MergeFrom(other.TypeField); break; case OneofFieldOneofCase.DoubleField: DoubleField = other.DoubleField; @@ -1945,6 +2009,7 @@ namespace Google.Protobuf.TestProtos { break; } + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -1953,7 +2018,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { global::Google.Protobuf.WellKnownTypes.Any subBuilder = new global::Google.Protobuf.WellKnownTypes.Any(); @@ -2085,6 +2150,7 @@ namespace Google.Protobuf.TestProtos { /// </summary> public sealed partial class MapWellKnownTypes : pb::IMessage<MapWellKnownTypes> { private static readonly pb::MessageParser<MapWellKnownTypes> _parser = new pb::MessageParser<MapWellKnownTypes>(() => new MapWellKnownTypes()); + private pb::UnknownFieldSet _unknownFields; [global::System.Diagnostics.DebuggerNonUserCodeAttribute] public static pb::MessageParser<MapWellKnownTypes> Parser { get { return _parser; } } @@ -2125,6 +2191,7 @@ namespace Google.Protobuf.TestProtos { boolField_ = other.boolField_.Clone(); stringField_ = other.stringField_.Clone(); bytesField_ = other.bytesField_.Clone(); + _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2343,7 +2410,7 @@ namespace Google.Protobuf.TestProtos { if (!BoolField.Equals(other.BoolField)) return false; if (!StringField.Equals(other.StringField)) return false; if (!BytesField.Equals(other.BytesField)) return false; - return true; + return Equals(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2367,6 +2434,9 @@ namespace Google.Protobuf.TestProtos { hash ^= BoolField.GetHashCode(); hash ^= StringField.GetHashCode(); hash ^= BytesField.GetHashCode(); + if (_unknownFields != null) { + hash ^= _unknownFields.GetHashCode(); + } return hash; } @@ -2395,6 +2465,9 @@ namespace Google.Protobuf.TestProtos { boolField_.WriteTo(output, _map_boolField_codec); stringField_.WriteTo(output, _map_stringField_codec); bytesField_.WriteTo(output, _map_bytesField_codec); + if (_unknownFields != null) { + _unknownFields.WriteTo(output); + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2418,6 +2491,9 @@ namespace Google.Protobuf.TestProtos { size += boolField_.CalculateSize(_map_boolField_codec); size += stringField_.CalculateSize(_map_stringField_codec); size += bytesField_.CalculateSize(_map_bytesField_codec); + if (_unknownFields != null) { + size += _unknownFields.CalculateSize(); + } return size; } @@ -2444,6 +2520,7 @@ namespace Google.Protobuf.TestProtos { boolField_.Add(other.boolField_); stringField_.Add(other.stringField_); bytesField_.Add(other.bytesField_); + _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute] @@ -2452,7 +2529,7 @@ namespace Google.Protobuf.TestProtos { while ((tag = input.ReadTag()) != 0) { switch(tag) { default: - input.SkipLastField(); + _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input); break; case 10: { anyField_.AddEntriesFrom(input, _map_anyField_codec); |