| Server IP : 162.214.74.102 / Your IP : 216.73.217.85 Web Server : Apache System : Linux dedi-4363141.lrsys.com.br 3.10.0-1160.119.1.el7.tuxcare.els25.x86_64 #1 SMP Wed Oct 1 17:37:27 UTC 2025 x86_64 User : lrsys ( 1015) PHP Version : 5.6.40 Disable Function : exec,passthru,shell_exec,system MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /proc/self/root/proc/self/root/opt/cpanel/ea-ruby24/root/usr/share/ri/system/Method/ |
Upload File : |
U:RDoc::AnyMethod[iI" curry:ETI"Method#curry;TF:publico:RDoc::Markup::Document:@parts[ o:RDoc::Markup::Paragraph; [ I"ZReturns a curried proc based on the method. When the proc is called with a number of ;TI"]arguments that is lower than the method's arity, then another curried proc is returned. ;TI"]Only when enough arguments have been supplied to satisfy the method signature, will the ;TI"method actually be called.;To:RDoc::Markup::BlankLine o; ; [I"VThe optional <i>arity</i> argument should be supplied when currying methods with ;TI"Xvariable arguments to determine how many arguments are needed before the method is ;TI"called.;T@o:RDoc::Markup::Verbatim; [I"def foo(a,b,c) ;TI" [a, b, c] ;TI" end ;TI" ;TI"%proc = self.method(:foo).curry ;TI"2proc2 = proc.call(1, 2) #=> #<Proc> ;TI"2proc2.call(3) #=> [1,2,3] ;TI" ;TI"def vararg(*args) ;TI" args ;TI" end ;TI" ;TI"*proc = self.method(:vararg).curry(4) ;TI",proc2 = proc.call(:x) #=> #<Proc> ;TI",proc3 = proc2.call(:y, :z) #=> #<Proc> ;TI"4proc3.call(:a) #=> [:x, :y, :z, :a];T:@format0: @fileI"proc.c;T:0@omit_headings_from_table_of_contents_below0I"9meth.curry -> proc meth.curry(arity) -> proc ;T0[ I"(*args);T@)FI"Method;TcRDoc::NormalClass00