Fix the doc for `DescriptorPool.lookup`

`DescriptorPool#lookup` returns `ServiceDescriptor` too since #15817.
pull/17639/head
yuuji.yaginuma 6 months ago
parent eceb8ccc0d
commit a011a56aa8
  1. 2
      ruby/ext/google/protobuf_c/defs.c
  2. 4
      ruby/src/main/java/com/google/protobuf/jruby/RubyDescriptorPool.java

@ -147,7 +147,7 @@ VALUE DescriptorPool_add_serialized_file(VALUE _self,
* call-seq:
* DescriptorPool.lookup(name) => descriptor
*
* Finds a Descriptor, EnumDescriptor or FieldDescriptor by name and returns it,
* Finds a Descriptor, EnumDescriptor, FieldDescriptor or ServiceDescriptor by name and returns it,
* or nil if none exists with the given name.
*/
static VALUE DescriptorPool_lookup(VALUE _self, VALUE name) {

@ -100,8 +100,8 @@ public class RubyDescriptorPool extends RubyObject {
* call-seq:
* DescriptorPool.lookup(name) => descriptor
*
* Finds a Descriptor, EnumDescriptor or FieldDescriptor by name and returns it, or nil if none
* exists with the given name.
* Finds a Descriptor, EnumDescriptor, FieldDescriptor or ServiceDescriptor by name and returns it,
* or nil if none exists with the given name.
*
* This currently lazy loads the ruby descriptor objects as they are requested.
* This allows us to leave the heavy lifting to the java library

Loading…
Cancel
Save