diff --git a/protoc_plugin/CHANGELOG.md b/protoc_plugin/CHANGELOG.md index 7ce0e7bb..f458a14c 100644 --- a/protoc_plugin/CHANGELOG.md +++ b/protoc_plugin/CHANGELOG.md @@ -4,6 +4,8 @@ * Read `default_host` and `oauth_scopes` options from gRPC service definitions and write that information to the generated gRPC clients. * Generate dartdocs for grpc services ([#973]). +* Adjust the deprecation messages for the message `clone()` and `copyWith()` + methods ([#998]). We now parse and generate code cooresponding to the proto options `google.api.default_host` and `google.api.oauth_scopes`: @@ -49,6 +51,7 @@ class FirestoreClient extends $grpc.Client { [#975]: https://github.com/google/protobuf.dart/issues/975 [#952]: https://github.com/google/protobuf.dart/issues/952 [#986]: https://github.com/google/protobuf.dart/issues/986 +[#998]: https://github.com/google/protobuf.dart/issues/998 ## 22.0.1 diff --git a/protoc_plugin/lib/src/generated/client.pb.dart b/protoc_plugin/lib/src/generated/client.pb.dart index ccb157d0..dfccc2d5 100644 --- a/protoc_plugin/lib/src/generated/client.pb.dart +++ b/protoc_plugin/lib/src/generated/client.pb.dart @@ -64,14 +64,10 @@ class CommonLanguageSettings extends $pb.GeneratedMessage { subBuilder: SelectiveGapicGeneration.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CommonLanguageSettings clone() => CommonLanguageSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CommonLanguageSettings copyWith( void Function(CommonLanguageSettings) updates) => super.copyWith((message) => updates(message as CommonLanguageSettings)) @@ -200,13 +196,9 @@ class Publishing extends $pb.GeneratedMessage { ..aOS(111, _omitFieldNames ? '' : 'restReferenceDocumentationUri') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Publishing clone() => Publishing()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Publishing copyWith(void Function(Publishing) updates) => super.copyWith((message) => updates(message as Publishing)) as Publishing; @@ -381,13 +373,9 @@ class JavaSettings extends $pb.GeneratedMessage { subBuilder: CommonLanguageSettings.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') JavaSettings clone() => JavaSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') JavaSettings copyWith(void Function(JavaSettings) updates) => super.copyWith((message) => updates(message as JavaSettings)) as JavaSettings; @@ -487,13 +475,9 @@ class CppSettings extends $pb.GeneratedMessage { subBuilder: CommonLanguageSettings.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CppSettings clone() => CppSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CppSettings copyWith(void Function(CppSettings) updates) => super.copyWith((message) => updates(message as CppSettings)) as CppSettings; @@ -552,13 +536,9 @@ class PhpSettings extends $pb.GeneratedMessage { subBuilder: CommonLanguageSettings.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhpSettings clone() => PhpSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhpSettings copyWith(void Function(PhpSettings) updates) => super.copyWith((message) => updates(message as PhpSettings)) as PhpSettings; @@ -629,14 +609,10 @@ class PythonSettings_ExperimentalFeatures extends $pb.GeneratedMessage { ..aOB(3, _omitFieldNames ? '' : 'unversionedPackageDisabled') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PythonSettings_ExperimentalFeatures clone() => PythonSettings_ExperimentalFeatures()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PythonSettings_ExperimentalFeatures copyWith( void Function(PythonSettings_ExperimentalFeatures) updates) => super.copyWith((message) => @@ -740,13 +716,9 @@ class PythonSettings extends $pb.GeneratedMessage { subBuilder: PythonSettings_ExperimentalFeatures.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PythonSettings clone() => PythonSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PythonSettings copyWith(void Function(PythonSettings) updates) => super.copyWith((message) => updates(message as PythonSettings)) as PythonSettings; @@ -822,13 +794,9 @@ class NodeSettings extends $pb.GeneratedMessage { subBuilder: CommonLanguageSettings.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') NodeSettings clone() => NodeSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') NodeSettings copyWith(void Function(NodeSettings) updates) => super.copyWith((message) => updates(message as NodeSettings)) as NodeSettings; @@ -923,13 +891,9 @@ class DotnetSettings extends $pb.GeneratedMessage { ..pPS(6, _omitFieldNames ? '' : 'handwrittenSignatures') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DotnetSettings clone() => DotnetSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DotnetSettings copyWith(void Function(DotnetSettings) updates) => super.copyWith((message) => updates(message as DotnetSettings)) as DotnetSettings; @@ -1024,13 +988,9 @@ class RubySettings extends $pb.GeneratedMessage { subBuilder: CommonLanguageSettings.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') RubySettings clone() => RubySettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') RubySettings copyWith(void Function(RubySettings) updates) => super.copyWith((message) => updates(message as RubySettings)) as RubySettings; @@ -1099,13 +1059,9 @@ class GoSettings extends $pb.GeneratedMessage { packageName: const $pb.PackageName('google.api')) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GoSettings clone() => GoSettings()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GoSettings copyWith(void Function(GoSettings) updates) => super.copyWith((message) => updates(message as GoSettings)) as GoSettings; @@ -1179,14 +1135,10 @@ class SelectiveGapicGeneration extends $pb.GeneratedMessage { ..aOB(2, _omitFieldNames ? '' : 'generateOmittedAsInternal') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SelectiveGapicGeneration clone() => SelectiveGapicGeneration()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SelectiveGapicGeneration copyWith( void Function(SelectiveGapicGeneration) updates) => super.copyWith((message) => updates(message as SelectiveGapicGeneration)) diff --git a/protoc_plugin/lib/src/generated/dart_options.pb.dart b/protoc_plugin/lib/src/generated/dart_options.pb.dart index 6de543ca..5487dd4b 100644 --- a/protoc_plugin/lib/src/generated/dart_options.pb.dart +++ b/protoc_plugin/lib/src/generated/dart_options.pb.dart @@ -52,13 +52,9 @@ class DartMixin extends $pb.GeneratedMessage { ..aOS(3, _omitFieldNames ? '' : 'parent') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DartMixin clone() => DartMixin()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DartMixin copyWith(void Function(DartMixin) updates) => super.copyWith((message) => updates(message as DartMixin)) as DartMixin; @@ -143,13 +139,9 @@ class Imports extends $pb.GeneratedMessage { subBuilder: DartMixin.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Imports clone() => Imports()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Imports copyWith(void Function(Imports) updates) => super.copyWith((message) => updates(message as Imports)) as Imports; diff --git a/protoc_plugin/lib/src/generated/descriptor.pb.dart b/protoc_plugin/lib/src/generated/descriptor.pb.dart index b505a400..316c81ad 100644 --- a/protoc_plugin/lib/src/generated/descriptor.pb.dart +++ b/protoc_plugin/lib/src/generated/descriptor.pb.dart @@ -49,13 +49,9 @@ class FileDescriptorSet extends $pb.GeneratedMessage { 1, _omitFieldNames ? '' : 'file', $pb.PbFieldType.PM, subBuilder: FileDescriptorProto.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileDescriptorSet clone() => FileDescriptorSet()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileDescriptorSet copyWith(void Function(FileDescriptorSet) updates) => super.copyWith((message) => updates(message as FileDescriptorSet)) as FileDescriptorSet; @@ -169,13 +165,9 @@ class FileDescriptorProto extends $pb.GeneratedMessage { 11, _omitFieldNames ? '' : 'weakDependency', $pb.PbFieldType.P3) ..aOS(12, _omitFieldNames ? '' : 'syntax'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileDescriptorProto clone() => FileDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileDescriptorProto copyWith(void Function(FileDescriptorProto) updates) => super.copyWith((message) => updates(message as FileDescriptorProto)) as FileDescriptorProto; @@ -325,14 +317,10 @@ class DescriptorProto_ExtensionRange extends $pb.GeneratedMessage { ..aOM(3, _omitFieldNames ? '' : 'options', subBuilder: ExtensionRangeOptions.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto_ExtensionRange clone() => DescriptorProto_ExtensionRange()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto_ExtensionRange copyWith( void Function(DescriptorProto_ExtensionRange) updates) => super.copyWith( @@ -425,14 +413,10 @@ class DescriptorProto_ReservedRange extends $pb.GeneratedMessage { ..a<$core.int>(2, _omitFieldNames ? '' : 'end', $pb.PbFieldType.O3) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto_ReservedRange clone() => DescriptorProto_ReservedRange()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto_ReservedRange copyWith( void Function(DescriptorProto_ReservedRange) updates) => super.copyWith( @@ -563,13 +547,9 @@ class DescriptorProto extends $pb.GeneratedMessage { subBuilder: DescriptorProto_ReservedRange.create) ..pPS(10, _omitFieldNames ? '' : 'reservedName'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto clone() => DescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') DescriptorProto copyWith(void Function(DescriptorProto) updates) => super.copyWith((message) => updates(message as DescriptorProto)) as DescriptorProto; @@ -667,14 +647,10 @@ class ExtensionRangeOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ExtensionRangeOptions clone() => ExtensionRangeOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ExtensionRangeOptions copyWith( void Function(ExtensionRangeOptions) updates) => super.copyWith((message) => updates(message as ExtensionRangeOptions)) @@ -782,14 +758,10 @@ class FieldDescriptorProto extends $pb.GeneratedMessage { ..aOS(10, _omitFieldNames ? '' : 'jsonName') ..aOB(17, _omitFieldNames ? '' : 'proto3Optional'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FieldDescriptorProto clone() => FieldDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FieldDescriptorProto copyWith(void Function(FieldDescriptorProto) updates) => super.copyWith((message) => updates(message as FieldDescriptorProto)) as FieldDescriptorProto; @@ -1014,14 +986,10 @@ class OneofDescriptorProto extends $pb.GeneratedMessage { ..aOM(2, _omitFieldNames ? '' : 'options', subBuilder: OneofOptions.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') OneofDescriptorProto clone() => OneofDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') OneofDescriptorProto copyWith(void Function(OneofDescriptorProto) updates) => super.copyWith((message) => updates(message as OneofDescriptorProto)) as OneofDescriptorProto; @@ -1103,14 +1071,10 @@ class EnumDescriptorProto_EnumReservedRange extends $pb.GeneratedMessage { ..a<$core.int>(2, _omitFieldNames ? '' : 'end', $pb.PbFieldType.O3) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumDescriptorProto_EnumReservedRange clone() => EnumDescriptorProto_EnumReservedRange()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumDescriptorProto_EnumReservedRange copyWith( void Function(EnumDescriptorProto_EnumReservedRange) updates) => super.copyWith((message) => @@ -1207,13 +1171,9 @@ class EnumDescriptorProto extends $pb.GeneratedMessage { subBuilder: EnumDescriptorProto_EnumReservedRange.create) ..pPS(5, _omitFieldNames ? '' : 'reservedName'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumDescriptorProto clone() => EnumDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumDescriptorProto copyWith(void Function(EnumDescriptorProto) updates) => super.copyWith((message) => updates(message as EnumDescriptorProto)) as EnumDescriptorProto; @@ -1309,14 +1269,10 @@ class EnumValueDescriptorProto extends $pb.GeneratedMessage { ..aOM(3, _omitFieldNames ? '' : 'options', subBuilder: EnumValueOptions.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumValueDescriptorProto clone() => EnumValueDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumValueDescriptorProto copyWith( void Function(EnumValueDescriptorProto) updates) => super.copyWith((message) => updates(message as EnumValueDescriptorProto)) @@ -1412,14 +1368,10 @@ class ServiceDescriptorProto extends $pb.GeneratedMessage { ..aOM(3, _omitFieldNames ? '' : 'options', subBuilder: ServiceOptions.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ServiceDescriptorProto clone() => ServiceDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ServiceDescriptorProto copyWith( void Function(ServiceDescriptorProto) updates) => super.copyWith((message) => updates(message as ServiceDescriptorProto)) @@ -1519,14 +1471,10 @@ class MethodDescriptorProto extends $pb.GeneratedMessage { ..aOB(5, _omitFieldNames ? '' : 'clientStreaming') ..aOB(6, _omitFieldNames ? '' : 'serverStreaming'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MethodDescriptorProto clone() => MethodDescriptorProto()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MethodDescriptorProto copyWith( void Function(MethodDescriptorProto) updates) => super.copyWith((message) => updates(message as MethodDescriptorProto)) @@ -1759,13 +1707,9 @@ class FileOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileOptions clone() => FileOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FileOptions copyWith(void Function(FileOptions) updates) => super.copyWith((message) => updates(message as FileOptions)) as FileOptions; @@ -2140,13 +2084,9 @@ class MessageOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MessageOptions clone() => MessageOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MessageOptions copyWith(void Function(MessageOptions) updates) => super.copyWith((message) => updates(message as MessageOptions)) as MessageOptions; @@ -2328,13 +2268,9 @@ class FieldOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FieldOptions clone() => FieldOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') FieldOptions copyWith(void Function(FieldOptions) updates) => super.copyWith((message) => updates(message as FieldOptions)) as FieldOptions; @@ -2509,13 +2445,9 @@ class OneofOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') OneofOptions clone() => OneofOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') OneofOptions copyWith(void Function(OneofOptions) updates) => super.copyWith((message) => updates(message as OneofOptions)) as OneofOptions; @@ -2575,13 +2507,9 @@ class EnumOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumOptions clone() => EnumOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumOptions copyWith(void Function(EnumOptions) updates) => super.copyWith((message) => updates(message as EnumOptions)) as EnumOptions; @@ -2665,13 +2593,9 @@ class EnumValueOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumValueOptions clone() => EnumValueOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') EnumValueOptions copyWith(void Function(EnumValueOptions) updates) => super.copyWith((message) => updates(message as EnumValueOptions)) as EnumValueOptions; @@ -2742,13 +2666,9 @@ class ServiceOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ServiceOptions clone() => ServiceOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') ServiceOptions copyWith(void Function(ServiceOptions) updates) => super.copyWith((message) => updates(message as ServiceOptions)) as ServiceOptions; @@ -2828,13 +2748,9 @@ class MethodOptions extends $pb.GeneratedMessage { subBuilder: UninterpretedOption.create) ..hasExtensions = true; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MethodOptions clone() => MethodOptions()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') MethodOptions copyWith(void Function(MethodOptions) updates) => super.copyWith((message) => updates(message as MethodOptions)) as MethodOptions; @@ -2920,14 +2836,10 @@ class UninterpretedOption_NamePart extends $pb.GeneratedMessage { ..a<$core.bool>( 2, _omitFieldNames ? '' : 'isExtension', $pb.PbFieldType.QB); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') UninterpretedOption_NamePart clone() => UninterpretedOption_NamePart()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') UninterpretedOption_NamePart copyWith( void Function(UninterpretedOption_NamePart) updates) => super.copyWith( @@ -3039,13 +2951,9 @@ class UninterpretedOption extends $pb.GeneratedMessage { 7, _omitFieldNames ? '' : 'stringValue', $pb.PbFieldType.OY) ..aOS(8, _omitFieldNames ? '' : 'aggregateValue'); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') UninterpretedOption clone() => UninterpretedOption()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') UninterpretedOption copyWith(void Function(UninterpretedOption) updates) => super.copyWith((message) => updates(message as UninterpretedOption)) as UninterpretedOption; @@ -3186,14 +3094,10 @@ class SourceCodeInfo_Location extends $pb.GeneratedMessage { ..pPS(6, _omitFieldNames ? '' : 'leadingDetachedComments') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SourceCodeInfo_Location clone() => SourceCodeInfo_Location()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SourceCodeInfo_Location copyWith( void Function(SourceCodeInfo_Location) updates) => super.copyWith((message) => updates(message as SourceCodeInfo_Location)) @@ -3350,13 +3254,9 @@ class SourceCodeInfo extends $pb.GeneratedMessage { subBuilder: SourceCodeInfo_Location.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SourceCodeInfo clone() => SourceCodeInfo()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') SourceCodeInfo copyWith(void Function(SourceCodeInfo) updates) => super.copyWith((message) => updates(message as SourceCodeInfo)) as SourceCodeInfo; @@ -3461,14 +3361,10 @@ class GeneratedCodeInfo_Annotation extends $pb.GeneratedMessage { ..a<$core.int>(4, _omitFieldNames ? '' : 'end', $pb.PbFieldType.O3) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GeneratedCodeInfo_Annotation clone() => GeneratedCodeInfo_Annotation()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GeneratedCodeInfo_Annotation copyWith( void Function(GeneratedCodeInfo_Annotation) updates) => super.copyWith( @@ -3567,13 +3463,9 @@ class GeneratedCodeInfo extends $pb.GeneratedMessage { subBuilder: GeneratedCodeInfo_Annotation.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GeneratedCodeInfo clone() => GeneratedCodeInfo()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') GeneratedCodeInfo copyWith(void Function(GeneratedCodeInfo) updates) => super.copyWith((message) => updates(message as GeneratedCodeInfo)) as GeneratedCodeInfo; diff --git a/protoc_plugin/lib/src/generated/plugin.pb.dart b/protoc_plugin/lib/src/generated/plugin.pb.dart index 30c8a8d1..2b23ada8 100644 --- a/protoc_plugin/lib/src/generated/plugin.pb.dart +++ b/protoc_plugin/lib/src/generated/plugin.pb.dart @@ -62,13 +62,9 @@ class Version extends $pb.GeneratedMessage { ..aOS(4, _omitFieldNames ? '' : 'suffix') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Version clone() => Version()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Version copyWith(void Function(Version) updates) => super.copyWith((message) => updates(message as Version)) as Version; @@ -178,14 +174,10 @@ class CodeGeneratorRequest extends $pb.GeneratedMessage { 15, _omitFieldNames ? '' : 'protoFile', $pb.PbFieldType.PM, subBuilder: $0.FileDescriptorProto.create); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorRequest clone() => CodeGeneratorRequest()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorRequest copyWith(void Function(CodeGeneratorRequest) updates) => super.copyWith((message) => updates(message as CodeGeneratorRequest)) as CodeGeneratorRequest; @@ -297,14 +289,10 @@ class CodeGeneratorResponse_File extends $pb.GeneratedMessage { subBuilder: $0.GeneratedCodeInfo.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorResponse_File clone() => CodeGeneratorResponse_File()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorResponse_File copyWith( void Function(CodeGeneratorResponse_File) updates) => super.copyWith( @@ -467,14 +455,10 @@ class CodeGeneratorResponse extends $pb.GeneratedMessage { subBuilder: CodeGeneratorResponse_File.create) ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorResponse clone() => CodeGeneratorResponse()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') CodeGeneratorResponse copyWith( void Function(CodeGeneratorResponse) updates) => super.copyWith((message) => updates(message as CodeGeneratorResponse)) diff --git a/protoc_plugin/lib/src/message_generator.dart b/protoc_plugin/lib/src/message_generator.dart index f26cec39..09d3251d 100644 --- a/protoc_plugin/lib/src/message_generator.dart +++ b/protoc_plugin/lib/src/message_generator.dart @@ -398,16 +398,12 @@ class MessageGenerator extends ProtobufContainer { } out.println(); - out.println('''@$coreImportPrefix.Deprecated( -'Using this can add significant overhead to your binary. ' -'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' -'Will be removed in next major version')'''); - out.println('$classname clone() =>' - ' $classname()..mergeFromMessage(this);'); - out.println('''@$coreImportPrefix.Deprecated( -'Using this can add significant overhead to your binary. ' -'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' -'Will be removed in next major version')'''); + out.println('@$coreImportPrefix.Deprecated(' + "'See https://github.com/google/protobuf.dart/issues/998.')"); + out.println( + '$classname clone() => $classname()..mergeFromMessage(this);'); + out.println('@$coreImportPrefix.Deprecated(' + "'See https://github.com/google/protobuf.dart/issues/998.')"); out.println('$classname copyWith(void Function($classname) updates) =>' ' super.copyWith((message) => updates(message as $classname))' ' as $classname;'); diff --git a/protoc_plugin/test/goldens/deprecations b/protoc_plugin/test/goldens/deprecations index 0e636e4e..f8db67bf 100644 --- a/protoc_plugin/test/goldens/deprecations +++ b/protoc_plugin/test/goldens/deprecations @@ -36,13 +36,9 @@ class HelloRequest extends $pb.GeneratedMessage { ..aOS(1, _omitFieldNames ? '' : 'name') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloRequest clone() => HelloRequest()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloRequest copyWith(void Function(HelloRequest) updates) => super.copyWith((message) => updates(message as HelloRequest)) as HelloRequest; @@ -93,13 +89,9 @@ class HelloReply extends $pb.GeneratedMessage { ..aOS(1, _omitFieldNames ? '' : 'message') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloReply clone() => HelloReply()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloReply copyWith(void Function(HelloReply) updates) => super.copyWith((message) => updates(message as HelloReply)) as HelloReply; diff --git a/protoc_plugin/test/goldens/doc_comments b/protoc_plugin/test/goldens/doc_comments index 55cb5467..e2bb23f7 100644 --- a/protoc_plugin/test/goldens/doc_comments +++ b/protoc_plugin/test/goldens/doc_comments @@ -36,13 +36,9 @@ class HelloRequest extends $pb.GeneratedMessage { ..aOS(1, _omitFieldNames ? '' : 'name') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloRequest clone() => HelloRequest()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloRequest copyWith(void Function(HelloRequest) updates) => super.copyWith((message) => updates(message as HelloRequest)) as HelloRequest; @@ -90,13 +86,9 @@ class HelloReply extends $pb.GeneratedMessage { ..aOS(1, _omitFieldNames ? '' : 'message') ..hasRequiredFields = false; - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloReply clone() => HelloReply()..mergeFromMessage(this); - @$core.Deprecated('Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') HelloReply copyWith(void Function(HelloReply) updates) => super.copyWith((message) => updates(message as HelloReply)) as HelloReply; diff --git a/protoc_plugin/test/goldens/grpc_service.pb b/protoc_plugin/test/goldens/grpc_service.pb index 6c3909f3..28311144 100644 --- a/protoc_plugin/test/goldens/grpc_service.pb +++ b/protoc_plugin/test/goldens/grpc_service.pb @@ -25,15 +25,9 @@ class Empty extends $pb.GeneratedMessage { ..hasRequiredFields = false ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Empty clone() => Empty()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Empty copyWith(void Function(Empty) updates) => super.copyWith((message) => updates(message as Empty)) as Empty; $pb.BuilderInfo get info_ => _i; diff --git a/protoc_plugin/test/goldens/imports.pb b/protoc_plugin/test/goldens/imports.pb index b8d1f3f9..23c06c07 100644 --- a/protoc_plugin/test/goldens/imports.pb +++ b/protoc_plugin/test/goldens/imports.pb @@ -31,15 +31,9 @@ class M extends $pb.GeneratedMessage { ..hasRequiredFields = false ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') M clone() => M()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') M copyWith(void Function(M) updates) => super.copyWith((message) => updates(message as M)) as M; $pb.BuilderInfo get info_ => _i; diff --git a/protoc_plugin/test/goldens/int64.pb b/protoc_plugin/test/goldens/int64.pb index fb09db21..7a4166c8 100644 --- a/protoc_plugin/test/goldens/int64.pb +++ b/protoc_plugin/test/goldens/int64.pb @@ -27,15 +27,9 @@ class Int64 extends $pb.GeneratedMessage { ..hasRequiredFields = false ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Int64 clone() => Int64()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Int64 copyWith(void Function(Int64) updates) => super.copyWith((message) => updates(message as Int64)) as Int64; $pb.BuilderInfo get info_ => _i; diff --git a/protoc_plugin/test/goldens/messageGenerator b/protoc_plugin/test/goldens/messageGenerator index 5eab0203..a26c8b0d 100644 --- a/protoc_plugin/test/goldens/messageGenerator +++ b/protoc_plugin/test/goldens/messageGenerator @@ -11,15 +11,9 @@ class PhoneNumber extends $pb.GeneratedMessage { ..aOS(4, _omitFieldNames ? '' : 'deprecatedField') ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhoneNumber clone() => PhoneNumber()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhoneNumber copyWith(void Function(PhoneNumber) updates) => super.copyWith((message) => updates(message as PhoneNumber)) as PhoneNumber; $pb.BuilderInfo get info_ => _i; diff --git a/protoc_plugin/test/goldens/messageGenerator.meta b/protoc_plugin/test/goldens/messageGenerator.meta index c398f603..52b316b0 100644 --- a/protoc_plugin/test/goldens/messageGenerator.meta +++ b/protoc_plugin/test/goldens/messageGenerator.meta @@ -18,8 +18,8 @@ annotation: { path: 2 path: 1 sourceFile: - begin: 2003 - end: 2009 + begin: 1786 + end: 1792 } annotation: { path: 4 @@ -27,8 +27,8 @@ annotation: { path: 2 path: 1 sourceFile: - begin: 2051 - end: 2057 + begin: 1834 + end: 1840 } annotation: { path: 4 @@ -36,8 +36,8 @@ annotation: { path: 2 path: 1 sourceFile: - begin: 2130 - end: 2139 + begin: 1913 + end: 1922 } annotation: { path: 4 @@ -45,8 +45,8 @@ annotation: { path: 2 path: 1 sourceFile: - begin: 2182 - end: 2193 + begin: 1965 + end: 1976 } annotation: { path: 4 @@ -54,8 +54,8 @@ annotation: { path: 2 path: 0 sourceFile: - begin: 2265 - end: 2269 + begin: 2048 + end: 2052 } annotation: { path: 4 @@ -63,8 +63,8 @@ annotation: { path: 2 path: 0 sourceFile: - begin: 2310 - end: 2314 + begin: 2093 + end: 2097 } annotation: { path: 4 @@ -72,8 +72,8 @@ annotation: { path: 2 path: 0 sourceFile: - begin: 2395 - end: 2402 + begin: 2178 + end: 2185 } annotation: { path: 4 @@ -81,8 +81,8 @@ annotation: { path: 2 path: 0 sourceFile: - begin: 2445 - end: 2454 + begin: 2228 + end: 2237 } annotation: { path: 4 @@ -90,8 +90,8 @@ annotation: { path: 2 path: 2 sourceFile: - begin: 2517 - end: 2521 + begin: 2300 + end: 2304 } annotation: { path: 4 @@ -99,8 +99,8 @@ annotation: { path: 2 path: 2 sourceFile: - begin: 2568 - end: 2572 + begin: 2351 + end: 2355 } annotation: { path: 4 @@ -108,8 +108,8 @@ annotation: { path: 2 path: 2 sourceFile: - begin: 2645 - end: 2652 + begin: 2428 + end: 2435 } annotation: { path: 4 @@ -117,8 +117,8 @@ annotation: { path: 2 path: 2 sourceFile: - begin: 2695 - end: 2704 + begin: 2478 + end: 2487 } annotation: { path: 4 @@ -126,8 +126,8 @@ annotation: { path: 2 path: 3 sourceFile: - begin: 2816 - end: 2831 + begin: 2599 + end: 2614 } annotation: { path: 4 @@ -135,8 +135,8 @@ annotation: { path: 2 path: 3 sourceFile: - begin: 2922 - end: 2937 + begin: 2705 + end: 2720 } annotation: { path: 4 @@ -144,8 +144,8 @@ annotation: { path: 2 path: 3 sourceFile: - begin: 3059 - end: 3077 + begin: 2842 + end: 2860 } annotation: { path: 4 @@ -153,6 +153,6 @@ annotation: { path: 2 path: 3 sourceFile: - begin: 3169 - end: 3189 + begin: 2952 + end: 2972 } diff --git a/protoc_plugin/test/goldens/oneMessage.pb b/protoc_plugin/test/goldens/oneMessage.pb index f01d1059..2ad0d7ed 100644 --- a/protoc_plugin/test/goldens/oneMessage.pb +++ b/protoc_plugin/test/goldens/oneMessage.pb @@ -27,15 +27,9 @@ class PhoneNumber extends $pb.GeneratedMessage { ..a<$core.String>(3, _omitFieldNames ? '' : 'name', $pb.PbFieldType.OS, defaultOrMaker: '\$') ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhoneNumber clone() => PhoneNumber()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') PhoneNumber copyWith(void Function(PhoneNumber) updates) => super.copyWith((message) => updates(message as PhoneNumber)) as PhoneNumber; $pb.BuilderInfo get info_ => _i; diff --git a/protoc_plugin/test/goldens/oneMessage.pb.meta b/protoc_plugin/test/goldens/oneMessage.pb.meta index 9e61c75f..c69336a9 100644 --- a/protoc_plugin/test/goldens/oneMessage.pb.meta +++ b/protoc_plugin/test/goldens/oneMessage.pb.meta @@ -18,8 +18,8 @@ annotation: { path: 2 path: 0 sourceFile: test - begin: 2327 - end: 2333 + begin: 2110 + end: 2116 } annotation: { path: 4 @@ -27,8 +27,8 @@ annotation: { path: 2 path: 0 sourceFile: test - begin: 2375 - end: 2381 + begin: 2158 + end: 2164 } annotation: { path: 4 @@ -36,8 +36,8 @@ annotation: { path: 2 path: 0 sourceFile: test - begin: 2454 - end: 2463 + begin: 2237 + end: 2246 } annotation: { path: 4 @@ -45,8 +45,8 @@ annotation: { path: 2 path: 0 sourceFile: test - begin: 2506 - end: 2517 + begin: 2289 + end: 2300 } annotation: { path: 4 @@ -54,8 +54,8 @@ annotation: { path: 2 path: 1 sourceFile: test - begin: 2577 - end: 2581 + begin: 2360 + end: 2364 } annotation: { path: 4 @@ -63,8 +63,8 @@ annotation: { path: 2 path: 1 sourceFile: test - begin: 2623 - end: 2627 + begin: 2406 + end: 2410 } annotation: { path: 4 @@ -72,8 +72,8 @@ annotation: { path: 2 path: 1 sourceFile: test - begin: 2702 - end: 2709 + begin: 2485 + end: 2492 } annotation: { path: 4 @@ -81,8 +81,8 @@ annotation: { path: 2 path: 1 sourceFile: test - begin: 2752 - end: 2761 + begin: 2535 + end: 2544 } annotation: { path: 4 @@ -90,8 +90,8 @@ annotation: { path: 2 path: 2 sourceFile: test - begin: 2824 - end: 2828 + begin: 2607 + end: 2611 } annotation: { path: 4 @@ -99,8 +99,8 @@ annotation: { path: 2 path: 2 sourceFile: test - begin: 2875 - end: 2879 + begin: 2658 + end: 2662 } annotation: { path: 4 @@ -108,8 +108,8 @@ annotation: { path: 2 path: 2 sourceFile: test - begin: 2952 - end: 2959 + begin: 2735 + end: 2742 } annotation: { path: 4 @@ -117,6 +117,6 @@ annotation: { path: 2 path: 2 sourceFile: test - begin: 3002 - end: 3011 + begin: 2785 + end: 2794 } diff --git a/protoc_plugin/test/goldens/service.pb b/protoc_plugin/test/goldens/service.pb index 098d7066..3de3da2b 100644 --- a/protoc_plugin/test/goldens/service.pb +++ b/protoc_plugin/test/goldens/service.pb @@ -26,15 +26,9 @@ class Empty extends $pb.GeneratedMessage { ..hasRequiredFields = false ; - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.deepCopy] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Empty clone() => Empty()..mergeFromMessage(this); - @$core.Deprecated( - 'Using this can add significant overhead to your binary. ' - 'Use [GeneratedMessageGenericExtensions.rebuild] instead. ' - 'Will be removed in next major version') + @$core.Deprecated('See https://github.com/google/protobuf.dart/issues/998.') Empty copyWith(void Function(Empty) updates) => super.copyWith((message) => updates(message as Empty)) as Empty; $pb.BuilderInfo get info_ => _i;