diff --git a/csharp/src/Google.Protobuf.Test.TestProtos/UnittestFeatures.pb.cs b/csharp/src/Google.Protobuf.Test.TestProtos/UnittestFeatures.pb.cs index beb8f16760..048b09037b 100644 --- a/csharp/src/Google.Protobuf.Test.TestProtos/UnittestFeatures.pb.cs +++ b/csharp/src/Google.Protobuf.Test.TestProtos/UnittestFeatures.pb.cs @@ -29,7 +29,7 @@ namespace Pb { "c3NhZ2UaTQoGTmVzdGVkMkMKC3Rlc3RfbmVzdGVkEhsuZ29vZ2xlLnByb3Rv", "YnVmLkZlYXR1cmVTZXQYjU4gASgLMhAucGIuVGVzdEZlYXR1cmVzMkQKDHRl", "c3RfbWVzc2FnZRIbLmdvb2dsZS5wcm90b2J1Zi5GZWF0dXJlU2V0GI5OIAEo", - "CzIQLnBiLlRlc3RGZWF0dXJlcyLbCgoMVGVzdEZlYXR1cmVzEnsKDGZpbGVf", + "CzIQLnBiLlRlc3RGZWF0dXJlcyKXDAoMVGVzdEZlYXR1cmVzEnsKDGZpbGVf", "ZmVhdHVyZRgBIAEoDjIPLnBiLkVudW1GZWF0dXJlQlSIAQGYAQGiAQsSBlZB", "TFVFMRiEB6IBCxIGVkFMVUUyGOcHogELEgZWQUxVRTMY6AeiAQwSBlZBTFVF", "NBidjQaiAQwSBlZBTFVFNRiejQayAQMI6AcSTAoXZXh0ZW5zaW9uX3Jhbmdl", @@ -59,19 +59,23 @@ namespace Pb { "IOkHElQKDmZ1dHVyZV9mZWF0dXJlGBIgASgOMg8ucGIuRW51bUZlYXR1cmVC", "K4gBAZgBAZgBBKIBCxIGVkFMVUUxGIQHogELEgZWQUxVRTIY6QeyAQMI6QcS", "VwoObGVnYWN5X2ZlYXR1cmUYEyABKA4yDy5wYi5FbnVtRmVhdHVyZUIuiAEB", - "mAEBmAEEogELEgZWQUxVRTEYhAeiAQsSBlZBTFVFMhjoB7IBBgjmByDoByrm", - "AQoLRW51bUZlYXR1cmUSHQoZVEVTVF9FTlVNX0ZFQVRVUkVfVU5LTk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XJlU2V0GI9OIAEoCzIQLnBiLlRlc3RGZWF0dXJlcw==")); descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData, new pbr::FileDescriptor[] { global::Google.Protobuf.Reflection.DescriptorReflection.Descriptor, }, new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Pb.EnumFeature), }, new pb::Extension[] { UnittestFeaturesExtensions.Test }, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Pb.TestMessage), global::Pb.TestMessage.Parser, null, null, null, new pb::Extension[] { global::Pb.TestMessage.Extensions.TestMessage }, new pbr::GeneratedClrTypeInfo[] { new pbr::GeneratedClrTypeInfo(typeof(global::Pb.TestMessage.Types.Nested), global::Pb.TestMessage.Types.Nested.Parser, null, null, null, new pb::Extension[] { global::Pb.TestMessage.Types.Nested.Extensions.TestNested }, null)}), - new pbr::GeneratedClrTypeInfo(typeof(global::Pb.TestFeatures), global::Pb.TestFeatures.Parser, new[]{ "FileFeature", "ExtensionRangeFeature", "MessageFeature", "FieldFeature", "OneofFeature", "EnumFeature", "EnumEntryFeature", "ServiceFeature", "MethodFeature", "MultipleFeature", "BoolFieldFeature", "SourceFeature", "SourceFeature2", "RemovedFeature", "FutureFeature", "LegacyFeature" }, null, null, null, null) + new pbr::GeneratedClrTypeInfo(typeof(global::Pb.TestFeatures), global::Pb.TestFeatures.Parser, new[]{ "FileFeature", "ExtensionRangeFeature", "MessageFeature", "FieldFeature", "OneofFeature", "EnumFeature", "EnumEntryFeature", "ServiceFeature", "MethodFeature", "MultipleFeature", "BoolFieldFeature", "SourceFeature", "SourceFeature2", "RemovedFeature", "FutureFeature", "LegacyFeature", "NoSupportWindowFeature", "EmptySupportWindowFeature" }, null, null, null, null) })); } #endregion @@ -509,6 +513,8 @@ namespace Pb { removedFeature_ = other.removedFeature_; futureFeature_ = other.futureFeature_; legacyFeature_ = other.legacyFeature_; + noSupportWindowFeature_ = other.noSupportWindowFeature_; + emptySupportWindowFeature_ = other.emptySupportWindowFeature_; _unknownFields = pb::UnknownFieldSet.Clone(other._unknownFields); } @@ -950,6 +956,60 @@ namespace Pb { _hasBits0 &= ~32768; } + /// Field number for the "no_support_window_feature" field. + public const int NoSupportWindowFeatureFieldNumber = 20; + private readonly static global::Pb.EnumFeature NoSupportWindowFeatureDefaultValue = global::Pb.EnumFeature.TestEnumFeatureUnknown; + + private global::Pb.EnumFeature noSupportWindowFeature_; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public global::Pb.EnumFeature NoSupportWindowFeature { + get { if ((_hasBits0 & 65536) != 0) { return noSupportWindowFeature_; } else { return NoSupportWindowFeatureDefaultValue; } } + set { + _hasBits0 |= 65536; + noSupportWindowFeature_ = value; + } + } + /// Gets whether the "no_support_window_feature" field is set + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public bool HasNoSupportWindowFeature { + get { return (_hasBits0 & 65536) != 0; } + } + /// Clears the value of the "no_support_window_feature" field + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public void ClearNoSupportWindowFeature() { + _hasBits0 &= ~65536; + } + + /// Field number for the "empty_support_window_feature" field. + public const int EmptySupportWindowFeatureFieldNumber = 21; + private readonly static global::Pb.EnumFeature EmptySupportWindowFeatureDefaultValue = global::Pb.EnumFeature.TestEnumFeatureUnknown; + + private global::Pb.EnumFeature emptySupportWindowFeature_; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public global::Pb.EnumFeature EmptySupportWindowFeature { + get { if ((_hasBits0 & 131072) != 0) { return emptySupportWindowFeature_; } else { return EmptySupportWindowFeatureDefaultValue; } } + set { + _hasBits0 |= 131072; + emptySupportWindowFeature_ = value; + } + } + /// Gets whether the "empty_support_window_feature" field is set + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public bool HasEmptySupportWindowFeature { + get { return (_hasBits0 & 131072) != 0; } + } + /// Clears the value of the "empty_support_window_feature" field + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] + [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] + public void ClearEmptySupportWindowFeature() { + _hasBits0 &= ~131072; + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute] [global::System.CodeDom.Compiler.GeneratedCode("protoc", null)] public override bool Equals(object other) { @@ -981,6 +1041,8 @@ namespace Pb { if (RemovedFeature != other.RemovedFeature) return false; if (FutureFeature != other.FutureFeature) return false; if (LegacyFeature != other.LegacyFeature) return false; + if (NoSupportWindowFeature != other.NoSupportWindowFeature) return false; + if (EmptySupportWindowFeature != other.EmptySupportWindowFeature) return false; return Equals(_unknownFields, other._unknownFields); } @@ -1004,6 +1066,8 @@ namespace Pb { if (HasRemovedFeature) hash ^= RemovedFeature.GetHashCode(); if (HasFutureFeature) hash ^= FutureFeature.GetHashCode(); if (HasLegacyFeature) hash ^= LegacyFeature.GetHashCode(); + if (HasNoSupportWindowFeature) hash ^= NoSupportWindowFeature.GetHashCode(); + if (HasEmptySupportWindowFeature) hash ^= EmptySupportWindowFeature.GetHashCode(); if (_unknownFields != null) { hash ^= _unknownFields.GetHashCode(); } @@ -1086,6 +1150,14 @@ namespace Pb { output.WriteRawTag(152, 1); output.WriteEnum((int) LegacyFeature); } + if (HasNoSupportWindowFeature) { + output.WriteRawTag(160, 1); + output.WriteEnum((int) NoSupportWindowFeature); + } + if (HasEmptySupportWindowFeature) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) EmptySupportWindowFeature); + } if (_unknownFields != null) { _unknownFields.WriteTo(output); } @@ -1160,6 +1232,14 @@ namespace Pb { output.WriteRawTag(152, 1); output.WriteEnum((int) LegacyFeature); } + if (HasNoSupportWindowFeature) { + output.WriteRawTag(160, 1); + output.WriteEnum((int) NoSupportWindowFeature); + } + if (HasEmptySupportWindowFeature) { + output.WriteRawTag(168, 1); + output.WriteEnum((int) EmptySupportWindowFeature); + } if (_unknownFields != null) { _unknownFields.WriteTo(ref output); } @@ -1218,6 +1298,12 @@ namespace Pb { if (HasLegacyFeature) { size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) LegacyFeature); } + if (HasNoSupportWindowFeature) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) NoSupportWindowFeature); + } + if (HasEmptySupportWindowFeature) { + size += 2 + pb::CodedOutputStream.ComputeEnumSize((int) EmptySupportWindowFeature); + } if (_unknownFields != null) { size += _unknownFields.CalculateSize(); } @@ -1278,6 +1364,12 @@ namespace Pb { if (other.HasLegacyFeature) { LegacyFeature = other.LegacyFeature; } + if (other.HasNoSupportWindowFeature) { + NoSupportWindowFeature = other.NoSupportWindowFeature; + } + if (other.HasEmptySupportWindowFeature) { + EmptySupportWindowFeature = other.EmptySupportWindowFeature; + } _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields); } @@ -1361,6 +1453,14 @@ namespace Pb { LegacyFeature = (global::Pb.EnumFeature) input.ReadEnum(); break; } + case 160: { + NoSupportWindowFeature = (global::Pb.EnumFeature) input.ReadEnum(); + break; + } + case 168: { + EmptySupportWindowFeature = (global::Pb.EnumFeature) input.ReadEnum(); + break; + } } } #endif @@ -1444,6 +1544,14 @@ namespace Pb { LegacyFeature = (global::Pb.EnumFeature) input.ReadEnum(); break; } + case 160: { + NoSupportWindowFeature = (global::Pb.EnumFeature) input.ReadEnum(); + break; + } + case 168: { + EmptySupportWindowFeature = (global::Pb.EnumFeature) input.ReadEnum(); + break; + } } } } diff --git a/csharp/src/Google.Protobuf.Test/testprotos.pb b/csharp/src/Google.Protobuf.Test/testprotos.pb index ce624353ca..a05e1d04ca 100644 Binary files a/csharp/src/Google.Protobuf.Test/testprotos.pb and b/csharp/src/Google.Protobuf.Test/testprotos.pb differ diff --git a/java/core/src/main/java/com/google/protobuf/JavaEditionDefaults.java b/java/core/src/main/java/com/google/protobuf/JavaEditionDefaults.java index 1cd713ba78..8ba264d326 100644 --- a/java/core/src/main/java/com/google/protobuf/JavaEditionDefaults.java +++ b/java/core/src/main/java/com/google/protobuf/JavaEditionDefaults.java @@ -4,7 +4,7 @@ package com.google.protobuf; public final class JavaEditionDefaults { - public static final String PROTOBUF_INTERNAL_JAVA_EDITION_DEFAULTS = "\n\030\022\023\010\001\020\002\030\002 \003(\0010\002\312>\004\010\001\020\001\030\346\007\n\030\022\023\010\002\020\001\030\001 \002(\0010\001\312>\004\010\000\020\001\030\347\007\n\030\022\023\010\001\020\001\030\001 \002(\0010\001\312>\004\010\000\020\001\030\350\007 \346\007(\350\007"; + public static final String PROTOBUF_INTERNAL_JAVA_EDITION_DEFAULTS = "\n5\022\026\010\001\020\002\030\002 \003(\0010\002\312>\004\010\001\020\001\312>\000\030\346\007\"\003\312>\000*\023\010\001\020\002\030\002 \003(\0010\002\312>\004\010\001\020\001\n5\022\026\010\002\020\001\030\001 \002(\0010\001\312>\004\010\000\020\001\312>\000\030\347\007\"\003\312>\000*\023\010\002\020\001\030\001 \002(\0010\001\312>\004\010\000\020\001\n5\022\026\010\001\020\001\030\001 \002(\0010\001\312>\000\312>\004\010\000\020\001\030\350\007\"\023\010\001\020\001\030\001 \002(\0010\001\312>\004\010\000\020\001*\003\312>\000 \346\007(\350\007"; private JavaEditionDefaults() {} } diff --git a/php/ext/google/protobuf/php-upb.h b/php/ext/google/protobuf/php-upb.h index 820add1527..ec2ce7c6c0 100644 --- a/php/ext/google/protobuf/php-upb.h +++ b/php/ext/google/protobuf/php-upb.h @@ -14239,7 +14239,7 @@ upb_ServiceDef* _upb_ServiceDefs_New(upb_DefBuilder* ctx, int n, // features. This is used for feature resolution under Editions. // NOLINTBEGIN // clang-format off -#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n\021\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\n\021\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\n\021\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007 \346\007(\350\007" +#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n!\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\"\000*\014\010\001\020\002\030\002 \003(\0010\002\n!\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\"\000*\014\010\002\020\001\030\001 \002(\0010\001\n!\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007\"\014\010\001\020\001\030\001 \002(\0010\001*\000 \346\007(\350\007" // clang-format on // NOLINTEND diff --git a/ruby/ext/google/protobuf_c/ruby-upb.h b/ruby/ext/google/protobuf_c/ruby-upb.h index 60196a0637..b97fee37c9 100755 --- a/ruby/ext/google/protobuf_c/ruby-upb.h +++ b/ruby/ext/google/protobuf_c/ruby-upb.h @@ -14053,7 +14053,7 @@ upb_ServiceDef* _upb_ServiceDefs_New(upb_DefBuilder* ctx, int n, // features. This is used for feature resolution under Editions. // NOLINTBEGIN // clang-format off -#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n\021\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\n\021\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\n\021\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007 \346\007(\350\007" +#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n!\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\"\000*\014\010\001\020\002\030\002 \003(\0010\002\n!\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\"\000*\014\010\002\020\001\030\001 \002(\0010\001\n!\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007\"\014\010\001\020\001\030\001 \002(\0010\001*\000 \346\007(\350\007" // clang-format on // NOLINTEND diff --git a/upb/reflection/internal/upb_edition_defaults.h b/upb/reflection/internal/upb_edition_defaults.h index b5fedd310a..71f8866a44 100644 --- a/upb/reflection/internal/upb_edition_defaults.h +++ b/upb/reflection/internal/upb_edition_defaults.h @@ -13,7 +13,7 @@ // features. This is used for feature resolution under Editions. // NOLINTBEGIN // clang-format off -#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n\021\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\n\021\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\n\021\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007 \346\007(\350\007" +#define UPB_INTERNAL_UPB_EDITION_DEFAULTS "\n!\022\014\010\001\020\002\030\002 \003(\0010\002\030\346\007\"\000*\014\010\001\020\002\030\002 \003(\0010\002\n!\022\014\010\002\020\001\030\001 \002(\0010\001\030\347\007\"\000*\014\010\002\020\001\030\001 \002(\0010\001\n!\022\014\010\001\020\001\030\001 \002(\0010\001\030\350\007\"\014\010\001\020\001\030\001 \002(\0010\001*\000 \346\007(\350\007" // clang-format on // NOLINTEND