1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/doc/irb/irb-tools.rd.jp

186 lines
4.6 KiB
Text
Raw Normal View History

irb$B4XO"$*$^$1%3%^%s%I$H%i%$%V%i%j(B
$Release Version: 0.7.1 $
$Revision$
$Date$
by Keiju ISHITSUKA(Nihon Rational Co.,Ltd.)
==begin
:$B%3%^%s%I(B:
* rtags -- ruby tags command
:$B4X?t%i%$%V%i%j(B:
* xmp -- irb version of gotoken xmp-function
:$B%/%i%9%i%$%V%i%j(B:
* frame.rb -- frame tracer
* completion.rb -- irb completor
= rtags
rtags$B$O(Bemacs$B5Z$S(Bvi$BMQ$N(B, TAG$B%U%!%$%k$r$D$/$k%3%^%s%I$G$9(B.
== $B;H$$J}(B
rtags [-vi] file....
$B%+%l%s%H%G%#%l%/%H%j$K(Bemacs$BMQ$N(BTAGS$B%U%!%$%k$,$G$-$^$9(B. -vi$B%*%W%7%g%s$r(B
$B$D$1$?;~$K$O(Bvi$BMQ$N(Btags$B%U%!%$%k$r:n@.$7$^$9(B.
emacs$B$N>l9g(B, $BDL>o$N(Betags.el$B$,$=$N$^$^;H$($^$9(B. $B8!:w2DG=$J$N$O(B,
* $B%/%i%9(B
* $B%a%=%C%I(B
* $BFC0[%a%=%C%I(B
* alias
* attr$B$G@k8@$5$l$?%"%/%;%5(B($B%Q%i%a!<%?$,%7%s%\%k$+J8;zNs%j%F%i%k$K8B$k(B)
* attr_XXX$B$G@k8@$5$l$?%"%/%;%5(B($B%Q%i%a!<%?$,%7%s%\%k$+J8;zNs%j%F%i%k$K8B$k(B)
$B$G$9(B.
C$B$J$I$G;H$C$F$$$k$N$H0c$&$N$O(B, $B%3%s%W%j!<%7%g%s$K4X$9$kItJ,$G(B,
$B4X?tL>$O(B,
$B4X?tL>(B(
$B%/%i%9$O(B,
::$B%/%i%9L>(B::....::$B%/%i%9L>(B
$B%a%=%C%I$O(B,
::$B%/%i%9L>(B::....::$B%/%i%9L>(B#$B%a%=%C%IL>(B
$BFC0[%a%=%C%I(B($B%/%i%9%a%=%C%I(B)$B$O(B
::$B%/%i%9L>(B::....::$B%/%i%9L>(B.$B%a%=%C%IL>(B
$B$G%3%s%W%j!<%7%g%s$r9T$J$&$H$3$m$G$9(B.
= xmp.rb
$B$4$H$1$s(Bxmp$B$N>e0L8_49%P!<%8%g%s$G$9(B. $B$?$@(B, $BHs>o$K=E$$$N$G$4$H$1$s(Bxmp$B$G(B
$B$OBP1~$G$-$J$$;~$K(B, $B;HMQ$9$k$HNI$$$G$7$g$&(B.
== $B;H$$J}(B
=== $B4X?t$H$7$F;H$&(B.
require "irb/xmp"
xmp <<END
foo = 1
foo
END
---
foo = 1
==>1
foo
==>1
=== XMP$B%$%s%9%?%s%9$rMQ$$$k(B.
$B$3$N>l9g$O(B, XMP$B$,%3%s%F%-%9%H>pJs$r;}$D$N$G(B, $BJQ?t$NCM$J$I$rJ];}$7$F$$(B
$B$^$9(B.
require "irb/xmp"
xmp = XMP.new
xmp.puts <<END
foo = 1
foo
END
xmp.puts <<END
foo
END
===
foo = 1
==>1
foo
==>1
foo
==>1
== $B%3%s%F%-%9%H$K4X$7$F(B
XMP$B%a%=%C%I72$N%3%s%F%-%9%H$O(B, $B8F$S=P$9A0$N%3%s%F%-%9%H$GI>2A$5$l$^$9(B.
$BL@<(E*$K%3%s%F%-%9%H$r;XDj$9$k$H$=$N%3%s%F%-%9%H$GI>2A$7$^$9(B.
$BNc(B:
xmp "foo", an_binding
:$BCm(B:
$B%^%k%A%9%l%C%I$K$OBP1~$7$F$$$^$;$s(B.
= frame.rb
$B8=:_<B9TCf$N%U%l!<%`>pJs$r<h$j07$&$?$a$N%/%i%9$G$9(B.
* IRB::Frame.top(n = 0)
$B>e$+$i(Bn$BHVL\$N%3%s%F%-%9%H$r<h$j=P$7$^$9(B. n$B$O(B0$B$,:G>e0L$K$J$j$^$9(B.
* IRB::Frame.bottom(n = 0)
$B2<$+$i(Bn$BHVL\$N%3%s%F%-%9%H$r<h$j=P$7$^$9(B. n$B$O(B0$B$,:G2<0L$K$J$j$^$9(B.
* IRB::Frame.sender
$B%;%s%@$K$J$C$F$$$k%*%V%8%'%/%H$r<h$j=P$7$^$9(B. $B%;%s%@$H$O(B, $B$=$N%a%=%C(B
$B%I$r8F$S=P$7$?B&$N(Bself$B$N$3$H$G$9(B.
:$BCm(B:
set_trace_func$B$rMQ$$$F(BRuby$B$N<B9T$r%H%l!<%9$7$F$$$^$9(B. $B%^%k%A%9%l%C%I$K(B
$B$OBP1~$7$F$$$^$;$s(B.
= completion.rb
irb$B$N(Bcompletion$B5!G=$rDs6!$9$k$b$N$G$9(B.
== $B;H$$J}(B
% irb -r irb/completion
$B$H$9$k$+(B, ~/.irbrc $BCf$K(B
require "irb/completion"
$B$rF~$l$F$/$@$5$$(B. irb$B<B9TCf$K(B require "irb/completion" $B$7$F$b$h$$$G$9(B.
irb$B<B9TCf$K(B (TAB) $B$r2!$9$H%3%s%W%l!<%7%g%s$7$^$9(B.
$B%H%C%W%l%Y%k$G(B(TAB)$B$r2!$9$H$9$Y$F$N9=J8MWAG(B, $B%/%i%9(B, $B%a%=%C%I$N8uJd$,$G(B
$B$^$9(B. $B8uJd$,M#0l$J$i$P40A4$KJd40$7$^$9(B.
irb(main):001:0> in
in inspect instance_eval
include install_alias_method instance_of?
initialize install_aliases instance_variables
irb(main):001:0> inspect
"main"
irb(main):002:0> foo = Object.new
#<Object:0x4027146c>
((|$BJQ?tL>(B.|))$B$N8e$K(B(TAB)$B$r2!$9$H(B, $B$=$N%*%V%8%'%/%H$N%a%=%C%I0lMw$,$G$^(B
$B$9(B.
irb(main):003:0> foo.
foo.== foo.frozen? foo.protected_methods
foo.=== foo.hash foo.public_methods
foo.=~ foo.id foo.respond_to?
foo.__id__ foo.inspect foo.send
foo.__send__ foo.instance_eval foo.singleton_methods
foo.class foo.instance_of? foo.taint
foo.clone foo.instance_variables foo.tainted?
foo.display foo.is_a? foo.to_a
foo.dup foo.kind_of? foo.to_s
foo.eql? foo.method foo.type
foo.equal? foo.methods foo.untaint
foo.extend foo.nil?
foo.freeze foo.private_methods
==end
% Begin Emacs Environment
% Local Variables:
% mode: text
% comment-column: 0
% comment-start: "%"
% comment-end: "\n"
% End:
%