Class: UnboundMethod
- Inherits:
-
Object
- Object
- UnboundMethod
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#source_location ⇒ Array, Fixnum
returns a pair of the Filename and line number on which the method is defined.
Instance Method Details
#source_location ⇒ Array, Fixnum
returns a pair of the Filename and line number on which the method is defined
returns nil if method has no associated ruby source code
107 108 109 110 111 112 113 114 115 116 117 118 |
# File 'ext/ruby18_source_location.c', line 107
static VALUE
method_source_location(VALUE method)
{
struct METHOD *data;
NODE *node;
Data_Get_Struct(method, struct METHOD, data);
if (node = data->body) {
return node_source_location(node);
}
return Qnil;
}
|