Sha256: b689a86a339bcc8ea0ce025beaefd68d02fb1934039c465718cf74de9ad8860c
Contents?: true
Size: 904 Bytes
Versions: 119
Compression:
Stored size: 904 Bytes
Contents
package com.xruby.GeneratedMethods; import com.xruby.runtime.lang.*; import com.xruby.runtime.builtin.RubyProc; public class RubyProc_Methods{ public static void initMethods( RubyClass klass){ klass.defineMethod( "arity", new RubyNoArgMethod(){ protected RubyValue run(RubyValue receiver, RubyBlock block ){ return ((RubyProc)receiver).arity();} }); klass.defineMethod( "==", new RubyOneArgMethod(){ protected RubyValue run(RubyValue receiver, RubyValue arg, RubyBlock block ){ return ((RubyProc)receiver).equal(arg);} }); klass.aliasMethod("==","eql?"); klass.getSingletonClass().defineMethod( "new", new RubyNoArgMethod(){ protected RubyValue run(RubyValue receiver, RubyBlock block ){ return RubyProc.newProc(receiver, block);} }); klass.defineMethod( "call", new RubyProc.Invoke() ); klass.aliasMethod("[]","call"); klass.aliasMethod("===","call"); klass.aliasMethod("yield","call"); }}
Version data entries
119 entries across 119 versions & 1 rubygems