[thrift] don't scope non-service types in Ruby
authorChristopher Piro <cpiro@apache.org>
Thu, 4 Oct 2007 01:54:11 +0000 (01:54 +0000)
committerChristopher Piro <cpiro@apache.org>
Thu, 4 Oct 2007 01:54:11 +0000 (01:54 +0000)
commite4e1968935f0dce5720f82baef19605f64512120
treebdf95efc989c54f684e5884105eb5cbaec886372
parent165eca9c7cdfcbc3b6ac4d8eeadb8e1c80a2584c
[thrift] don't scope non-service types in Ruby

Summary: non-service types live in the top-level namespace, so look for them there. example from FacebookService.rb (accessing Service from reflection_limited_types.rb):

              FIELDS = {
         -      0 => {:type => TType::STRUCT, :name => 'success', :class => reflection_limited_types.Service}
         +      0 => {:type => TType::STRUCT, :name => 'success', :class => Service}
              }

         preferable to adding a "module honk_types ... end" around honk_types.rb ... non-service types should land in top-level space (or whatever ruby_namespace has been defined).  if ruby_namespace even works ... who knows

Reviewed By: mcslee

Test Plan: now reflection_limited works with my simple Ruby client

           honestly, there's no test suite for these?  TODO:cpiro

Revert: OK

TracCamp Project: Thrift

DiffCamp Revision: 735

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665291 13f79535-47bb-0310-9956-ffa450edef68
compiler/cpp/src/generate/t_rb_generator.cc