vm/instructions.rb
# [Operation]
#   Locates a method by searching the \class hierarchy from a specified
#   object
# [Format]
#   \locate_method
# [Stack Before]
#   * include_private
#   * method_name
#   * self
#   * ...
# [Stack After]
#   * method
#   * ...
# [Description]
#   Pops a flag indicating whether or not to search in private methods, the
#   method name, and the object to search from off the stack. If a matching
#   method is located, the module it was found in and the method is pushed
#   onto the stack; otherwise, nil is pushed onto the stack.
#
# @todo Need to remove redundancy here and send_*. --rue
[Operation]
Locates a method by searching the \class hierarchy from a specified
object
[Format]
\locate_method
[Stack Before]
include_private
method_name
self

[Stack After]
method

[Description]
Pops a flag indicating whether or not to search in private methods, the
method name, and the object to search from off the stack. If a matching
method is located, the module it was found in and the method is pushed
onto the stack; otherwise, nil is pushed onto the stack.
[ Operation ] Locates a method by searching the \ class hierarchy from a specified object [ Format ] \ locate_method [ Stack Before ] include_private method_name self [ Stack After ] method [ Description ] Pops a flag indicating whether or not to search in private methods the method name and the object to search from off the stack . If a matching method is located the module it was found in and the method is pushed onto the stack ; otherwise nil is pushed onto the stack .
def locate_method
    <<-CODE
    Object* t1 = stack_pop(); // include_private
    Symbol* name = as<Symbol>(stack_pop()); // meth
    Object* t3 = stack_pop(); // self
    stack_push(Helpers::locate_method_on(state, call_frame, t3, name, t1));
    CODE
  end
def locate_method <<-CODE 
    Object* t1 = stack_pop(); // include_private
    Symbol* name = as<Symbol>(stack_pop()); // meth
    Object* t3 = stack_pop(); // self
    stack_push(Helpers::locate_method_on(state, call_frame, t3, name, t1));
     CODE end
[Operation]
Locates a method by searching the \class hierarchy from a specified
object
[Format]
\locate_method
[Stack Before]
 include_private
 method_name
 self
 ...
[Stack After]
 method
 ...
[Description]
Pops a flag indicating whether or not to search in private methods, the
method name, and the object to search from off the stack.
[ Operation ] Locates a method by searching the \ class hierarchy from a specified object [ Format ] \ locate_method [ Stack Before ] include_private method_name self ... [ Stack After ] method ... [ Description ] Pops a flag indicating whether or not to search in private methods the method name and the object to search from off the stack .
todo
Need to remove redundancy here and send_*. --rue
Need to remove redundancy here and send_ * . -- rue