Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update ruby_generator.cc to allow proto2 imports in proto3 (#9003)
* Update ruby_generator.cc to allow proto2 imports in proto3, with updated unit tests * Update Makefile.am with new ruby_generated_code_proto2_import.proto * Fix ruby_generator unit test to use temporary test directory for imported protos * Add test for imported proto2 to ruby/tests * Fix proto_path, restore to ../src/protoc, and fix/cleanup unit test. * Rename Proto2TestMessage to TestImportedMessage for consistency, for ruby compiler tests
- Loading branch information
Showing
11 changed files
with
49 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
src/google/protobuf/compiler/ruby/ruby_generated_code_proto2_import.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
syntax = "proto2"; | ||
|
||
package A.B.C; | ||
|
||
message TestImportedMessage {} |
2 changes: 2 additions & 0 deletions
2
src/google/protobuf/compiler/ruby/ruby_generated_code_proto2_pb.rb
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters