diff options
Diffstat (limited to 'ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java')
-rw-r--r-- | ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java b/ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java index 51c50be8..dd9179b0 100644 --- a/ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java +++ b/ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptor.java @@ -248,6 +248,8 @@ public class RubyDescriptor extends RubyObject { klass.setAllocator(allocator); klass.makeMetaClass(runtime.getObject().getMetaClass()); klass.inherit(runtime.getObject()); + RubyModule messageExts = runtime.getClassFromPath("Google::Protobuf::MessageExts"); + klass.include(new IRubyObject[] {messageExts}); klass.instance_variable_set(runtime.newString(Utils.DESCRIPTOR_INSTANCE_VAR), this); klass.defineAnnotatedMethods(RubyMessage.class); return klass; |