Commit 1024cbea authored by Andrei Shevtsov's avatar Andrei Shevtsov Committed by Paul Yang

Fix ruby proto3 extension support (#6369)

parent a9bb6564
......@@ -537,7 +537,8 @@ bool GenerateFile(const FileDescriptor* file, io::Printer* printer,
}
// TODO: Remove this when ruby supports extensions for proto2 syntax.
if (file->extension_count() > 0) {
if (file->syntax() == FileDescriptor::SYNTAX_PROTO2 &&
file->extension_count() > 0) {
*error = "Extensions are not yet supported for proto2 .proto files.";
return false;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment