Skip to content

Commit

Permalink
update to newer protoc v3.19 (#497)
Browse files Browse the repository at this point in the history
  • Loading branch information
jhump committed Feb 15, 2022
1 parent 3f69e23 commit d6def3b
Show file tree
Hide file tree
Showing 30 changed files with 271 additions and 260 deletions.
19 changes: 10 additions & 9 deletions desc/protoprint/testfiles/descriptor-compact.proto
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
// without any other information (e.g. without reading its imports).
syntax = "proto2";
package google.protobuf;
option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";
option java_package = "com.google.protobuf";
option java_outer_classname = "DescriptorProtos";
option csharp_namespace = "Google.Protobuf.Reflection";
Expand Down Expand Up @@ -289,16 +289,16 @@ message FileOptions {
// inappropriate because proto packages do not normally start with backwards
// domain names.
optional string java_package = 1;
// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;
// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -407,6 +407,7 @@ message MessageOptions {
// for the message, or it will be completely ignored; in the very least,
// this is a formalization for deprecating messages.
optional bool deprecated = 3 [default = false];
reserved 4, 5, 6;
// Whether the message is an automatically generated map entry type for the
// maps field.
//
Expand Down
20 changes: 10 additions & 10 deletions desc/protoprint/testfiles/descriptor-custom-sort.proto
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ message MethodDescriptorProto {
}

message MessageOptions {
reserved 9, 8;
reserved 9, 8, 6, 5, 4;

extensions 1000 to max;

Expand Down Expand Up @@ -493,17 +493,17 @@ message FileOptions {
// domain names.
optional string java_package = 1;

// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;

// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -938,7 +938,7 @@ option java_package = "com.google.protobuf";

option java_outer_classname = "DescriptorProtos";

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option csharp_namespace = "Google.Protobuf.Reflection";

Expand Down
20 changes: 11 additions & 9 deletions desc/protoprint/testfiles/descriptor-default.proto
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ syntax = "proto2";

package google.protobuf;

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_package = "com.google.protobuf";

Expand Down Expand Up @@ -386,17 +386,17 @@ message FileOptions {
// domain names.
optional string java_package = 1;

// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;

// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -532,6 +532,8 @@ message MessageOptions {
// this is a formalization for deprecating messages.
optional bool deprecated = 3 [default = false];

reserved 4, 5, 6;

// Whether the message is an automatically generated map entry type for the
// maps field.
//
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ syntax = "proto2";

package google.protobuf;

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_package = "com.google.protobuf";

Expand Down Expand Up @@ -441,19 +441,19 @@ message FileOptions {
optional string java_package = 1;

/*
* If set, all the classes from the .proto file are wrapped in a single
* outer class with the given name. This applies to both Proto1
* (equivalent to the old "--one_java_file" option) and Proto2 (where
* a .proto always translates to a single class, but you may want to
* explicitly choose the class name).
* Controls the name of the wrapper Java class generated for the .proto file.
* That class will always contain the .proto file's getDescriptor() method as
* well as any top-level extensions defined in the .proto file.
* If java_multiple_files is disabled, then all the other classes from the
* .proto file will be nested inside the single wrapper outer class.
*/
optional string java_outer_classname = 8;

/*
* If set true, then the Java code generator will generate a separate .java
* If enabled, then the Java code generator will generate a separate .java
* file for each top-level message, enum, and service defined in the .proto
* file. Thus, these types will *not* be nested inside the outer class
* named by java_outer_classname. However, the outer class will still be
* file. Thus, these types will *not* be nested inside the wrapper class
* named by java_outer_classname. However, the wrapper class will still be
* generated to contain the file's getDescriptor() method as well as any
* top-level extensions defined in the file.
*/
Expand Down Expand Up @@ -620,6 +620,8 @@ message MessageOptions {
*/
optional bool deprecated = 3 [default = false];

reserved 4, 5, 6;

/*
* Whether the message is an automatically generated map entry type for the
* maps field.
Expand Down
20 changes: 11 additions & 9 deletions desc/protoprint/testfiles/descriptor-no-trailing-comments.proto
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ syntax = "proto2";

package google.protobuf;

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_package = "com.google.protobuf";

Expand Down Expand Up @@ -386,17 +386,17 @@ message FileOptions {
// domain names.
optional string java_package = 1;

// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;

// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -532,6 +532,8 @@ message MessageOptions {
// this is a formalization for deprecating messages.
optional bool deprecated = 3 [default = false];

reserved 4, 5, 6;

// Whether the message is an automatically generated map entry type for the
// maps field.
//
Expand Down
20 changes: 11 additions & 9 deletions desc/protoprint/testfiles/descriptor-only-doc-comments.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ syntax = "proto2";

package google.protobuf;

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_package = "com.google.protobuf";

Expand Down Expand Up @@ -314,17 +314,17 @@ message FileOptions {
// domain names.
optional string java_package = 1;

// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;

// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -460,6 +460,8 @@ message MessageOptions {
// this is a formalization for deprecating messages.
optional bool deprecated = 3 [default = false];

reserved 4, 5, 6;

// Whether the message is an automatically generated map entry type for the
// maps field.
//
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ option cc_enable_arenas = true;

option csharp_namespace = "Google.Protobuf.Reflection";

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_outer_classname = "DescriptorProtos";

Expand Down Expand Up @@ -546,21 +546,21 @@ message FileOptions {
optional string java_package = 1;

/*
* If set, all the classes from the .proto file are wrapped in a single
* outer class with the given name. This applies to both Proto1
* (equivalent to the old "--one_java_file" option) and Proto2 (where
* a .proto always translates to a single class, but you may want to
* explicitly choose the class name).
* Controls the name of the wrapper Java class generated for the .proto file.
* That class will always contain the .proto file's getDescriptor() method as
* well as any top-level extensions defined in the .proto file.
* If java_multiple_files is disabled, then all the other classes from the
* .proto file will be nested inside the single wrapper outer class.
*/
optional string java_outer_classname = 8;

optional OptimizeMode optimize_for = 9 [default = SPEED];

/*
* If set true, then the Java code generator will generate a separate .java
* If enabled, then the Java code generator will generate a separate .java
* file for each top-level message, enum, and service defined in the .proto
* file. Thus, these types will *not* be nested inside the outer class
* named by java_outer_classname. However, the outer class will still be
* file. Thus, these types will *not* be nested inside the wrapper class
* named by java_outer_classname. However, the wrapper class will still be
* generated to contain the file's getDescriptor() method as well as any
* top-level extensions defined in the file.
*/
Expand Down Expand Up @@ -792,7 +792,7 @@ message MessageOptions {

extensions 1000 to max;

reserved 8, 9;
reserved 4, 5, 6, 8, 9;
}

/* Describes a method of a service. */
Expand Down
20 changes: 10 additions & 10 deletions desc/protoprint/testfiles/descriptor-sorted.proto
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ option cc_enable_arenas = true;

option csharp_namespace = "Google.Protobuf.Reflection";

option go_package = "github.com/golang/protobuf/protoc-gen-go/descriptor;descriptor";
option go_package = "google.golang.org/protobuf/types/descriptorpb";

option java_outer_classname = "DescriptorProtos";

Expand Down Expand Up @@ -407,19 +407,19 @@ message FileOptions {
// domain names.
optional string java_package = 1;

// If set, all the classes from the .proto file are wrapped in a single
// outer class with the given name. This applies to both Proto1
// (equivalent to the old "--one_java_file" option) and Proto2 (where
// a .proto always translates to a single class, but you may want to
// explicitly choose the class name).
// Controls the name of the wrapper Java class generated for the .proto file.
// That class will always contain the .proto file's getDescriptor() method as
// well as any top-level extensions defined in the .proto file.
// If java_multiple_files is disabled, then all the other classes from the
// .proto file will be nested inside the single wrapper outer class.
optional string java_outer_classname = 8;

optional OptimizeMode optimize_for = 9 [default = SPEED];

// If set true, then the Java code generator will generate a separate .java
// If enabled, then the Java code generator will generate a separate .java
// file for each top-level message, enum, and service defined in the .proto
// file. Thus, these types will *not* be nested inside the outer class
// named by java_outer_classname. However, the outer class will still be
// file. Thus, these types will *not* be nested inside the wrapper class
// named by java_outer_classname. However, the wrapper class will still be
// generated to contain the file's getDescriptor() method as well as any
// top-level extensions defined in the file.
optional bool java_multiple_files = 10 [default = false];
Expand Down Expand Up @@ -608,7 +608,7 @@ message MessageOptions {

extensions 1000 to max;

reserved 8, 9;
reserved 4, 5, 6, 8, 9;
}

// Describes a method of a service.
Expand Down

0 comments on commit d6def3b

Please sign in to comment.