Skip to content

Commit

Permalink
Switch to using protobuf's helper for the file's prefix. (#26605)
Browse files Browse the repository at this point in the history
This adds support for protobuf ObjC support for using the proto package to
define the prefix for the file
(protocolbuffers/protobuf#8760).

Once protobuf cuts a release, it likely makes sense to support the same
generator options that the objc generator does, but for now the environment
variable support can used to enable this when building from recent sources.
  • Loading branch information
thomasvl committed Jul 14, 2021
1 parent 987d526 commit 434f90b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/compiler/objective_c_generator_helpers.h
Expand Up @@ -37,7 +37,7 @@ inline string MessageHeaderName(const FileDescriptor* file) {

inline string ServiceClassName(const ServiceDescriptor* service) {
const FileDescriptor* file = service->file();
string prefix = file->options().objc_class_prefix();
string prefix = google::protobuf::compiler::objectivec::FileClassPrefix(file);
return prefix + service->name();
}

Expand Down

0 comments on commit 434f90b

Please sign in to comment.