Skip to content

Commit

Permalink
compiler/cpp/src/generate/t_rb_generator: Handle properly the import …
Browse files Browse the repository at this point in the history
…of std files
  • Loading branch information
AlexisMontagne committed Oct 11, 2024
1 parent ab481d2 commit 152a310
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
5 changes: 5 additions & 0 deletions compiler/cpp/src/generate/t_rb_generator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1228,6 +1228,11 @@ string t_rb_generator::type_name(t_type* ttype) {

string t_rb_generator::full_type_name(t_type* ttype) {
string prefix = "::";

if (ttype->get_program()->is_std_path()) {
prefix += "Thrift::";
}

vector<std::string> modules = ruby_modules(ttype->get_program());
for (vector<std::string>::iterator m_iter = modules.begin(); m_iter != modules.end(); ++m_iter) {
prefix += *m_iter + "::";
Expand Down
6 changes: 3 additions & 3 deletions lib/rb/thrift.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)

Gem::Specification.new do |s|
s.name = 'upfluence-thrift'
s.version = '2.5.0'
s.version = `git describe --tag`.chomp[1..]
s.authors = ['Thrift Developers']
s.email = ['dev@thrift.apache.org']
s.homepage = 'http://thrift.apache.org'
Expand All @@ -27,10 +27,10 @@ Gem::Specification.new do |s|

s.require_paths = %w[lib ext]

s.add_development_dependency 'rspec', '~> 2.10.0'
s.add_development_dependency 'rspec'
s.add_development_dependency "rack"
s.add_development_dependency "rack-test"
s.add_development_dependency "thin", "~> 1.5.0"
s.add_development_dependency "thin"
s.add_development_dependency "bundler"
s.add_development_dependency 'rake'
end
Expand Down

0 comments on commit 152a310

Please sign in to comment.