6827件ヒット
[1-100件を表示]
(0.060秒)
別のキーワード
クラス
-
ARGF
. class (108) - Array (93)
- Binding (7)
- Class (12)
- Complex (24)
- Data (12)
- Dir (172)
- Encoding (78)
-
Encoding
:: Converter (96) -
Encoding
:: InvalidByteSequenceError (12) -
Encoding
:: UndefinedConversionError (12) - Exception (80)
- FalseClass (24)
- Fiber (10)
- File (180)
-
File
:: Stat (24) - Float (36)
- Hash (112)
- IO (190)
- Integer (76)
- MatchData (160)
- Method (36)
- Module (288)
- Mutex (2)
- NilClass (12)
- Numeric (12)
- Object (195)
- Proc (36)
- Random (29)
- Range (38)
- Rational (36)
- Regexp (189)
- RubyVM (24)
-
RubyVM
:: AbstractSyntaxTree :: Node (49) -
RubyVM
:: InstructionSequence (246) - Set (9)
- SignalException (12)
- String (2150)
- Struct (347)
- Symbol (5)
- Thread (90)
-
Thread
:: Backtrace :: Location (84) -
Thread
:: Mutex (10) - Time (68)
- TracePoint (225)
- TrueClass (60)
- UnboundMethod (36)
- UncaughtThrowError (11)
モジュール
- Enumerable (48)
- GC (36)
-
GC
:: Profiler (12) - Kernel (683)
- Marshal (12)
- ObjectSpace (12)
- Process (24)
-
RubyVM
:: AbstractSyntaxTree (30) -
RubyVM
:: MJIT (7) - Signal (24)
オブジェクト
- ENV (60)
キーワード
-
$ & (12) -
$ & # 39; (12) -
$ * (12) -
$ , (12) -
$ -0 (12) -
$ -F (12) -
$ -I (12) -
$ / (12) -
$ 0 (12) -
$ 1 (12) -
$ 10 (12) -
$ 11 (12) -
$ 2 (12) -
$ 3 (12) -
$ 4 (12) -
$ 5 (12) -
$ 6 (12) -
$ 7 (12) -
$ 8 (12) -
$ 9 (12) -
$ : (12) -
$ ; (12) -
$ LOAD _ PATH (12) -
$ PROGRAM _ NAME (12) -
$ _ (12) -
$ ` (12) - % (12)
- & (12)
- * (24)
- + (12)
- +@ (10)
- -@ (10)
- << (12)
- <=> (12)
- == (24)
- === (24)
- =~ (24)
- AbstractSyntaxTree (7)
-
CESU
_ 8 (6) - Complex (14)
- Float (7)
-
INSTRUCTION
_ NAMES (12) - InstructionSequence (12)
- Integer (7)
- Location (12)
- Node (7)
- OPTS (12)
-
RUBY
_ COPYRIGHT (12) -
RUBY
_ DESCRIPTION (12) -
RUBY
_ ENGINE (12) -
RUBY
_ ENGINE _ VERSION (10) -
RUBY
_ PLATFORM (12) -
RUBY
_ RELEASE _ DATE (12) -
RUBY
_ REVISION (6) -
RUBY
_ VERSION (12) - Rational (7)
- String (24)
- TRUE (8)
- TracePoint (12)
- [] (168)
- []= (96)
- ^ (12)
-
_ dump (12) -
_ load (12) - ` (12)
-
absolute
_ path (36) -
add
_ trace _ func (12) -
append
_ as _ bytes (1) - argv0 (12)
-
asciicompat
_ encoding (12) - asctime (12)
- attr (36)
-
attr
_ accessor (12) -
attr
_ reader (12) -
attr
_ writer (12) - autoload? (24)
- b (12)
- backtrace (24)
-
backtrace
_ locations (36) -
base
_ label (24) - basename (12)
- binding (12)
- binread (12)
- binwrite (12)
- byteindex (3)
- byterindex (3)
- bytes (43)
- bytesize (12)
- byteslice (36)
-
callee
_ id (12) - caller (36)
-
caller
_ locations (24) - capitalize (12)
- capitalize! (12)
- captures (12)
- casecmp (12)
- casecmp? (9)
- center (12)
- chars (24)
- children (30)
- chomp (24)
- chomp! (12)
- chop (24)
- chop! (12)
- chr (36)
-
class
_ variables (12) - clear (12)
- clone (12)
- codepoints (24)
- compile (24)
-
compile
_ file (12) -
compile
_ option (12) -
compile
_ option= (12) - concat (21)
-
const
_ defined? (12) -
const
_ get (12) -
const
_ source _ location (12) - constants (12)
- convert (12)
-
copy
_ stream (24) - count (12)
- crypt (12)
- ctime (12)
- deconstruct (11)
-
deconstruct
_ keys (13) - dedup (3)
-
defined
_ class (12) - delete (36)
- delete! (12)
-
delete
_ prefix (8) -
delete
_ prefix! (8) -
delete
_ suffix (8) -
delete
_ suffix! (8) - dev (12)
- dig (10)
- dirname (12)
- disable (24)
- disasm (24)
- disassemble (24)
- downcase (12)
- downcase! (12)
- dump (24)
- each (24)
-
each
_ byte (24) -
each
_ char (24) -
each
_ codepoint (24) -
each
_ entry (24) -
each
_ grapheme _ cluster (16) -
each
_ line (24) -
each
_ pair (24) - empty? (12)
- enable (24)
- encode (36)
- encode! (24)
- encoding (12)
-
end
_ with? (12) - entries (43)
- eql? (24)
-
error
_ bytes (12) -
error
_ char (12) - escape (12)
- eval (12)
-
eval
_ script (7) - event (12)
- exit (12)
- extname (12)
- fail (12)
- filename (12)
- filter (14)
- finish (12)
-
first
_ column (7) -
first
_ lineno (19) -
force
_ encoding (12) - format (12)
- ftype (24)
-
garbage
_ collect (24) - getbyte (12)
- getc (12)
- gets (48)
- getwd (12)
- glob (17)
-
grapheme
_ clusters (16) - gsub (72)
- gsub! (48)
- hash (24)
- hex (12)
- home (24)
- include? (12)
- index (12)
-
inplace
_ mode (12) - insert (12)
-
insert
_ output (12) - inspect (319)
-
instance
_ methods (12) -
instruction
_ sequence (7) - integer? (12)
- intern (12)
- join (24)
-
keyword
_ init? (4) - label (24)
-
last
_ column (7) -
last
_ lineno (7) -
last
_ match (12) - length (24)
- lineno (24)
- lines (24)
- ljust (12)
- load (12)
-
load
_ from _ binary (10) -
load
_ from _ binary _ extra _ data (10) -
locale
_ charmap (12) - lstrip (12)
- lstrip! (12)
- match (48)
- match? (18)
- members (24)
-
method
_ defined? (12) -
method
_ id (12) - methods (12)
-
module
_ function (12) - name (29)
- name= (10)
-
name
_ list (12) -
named
_ captures (12) - names (36)
- new (103)
- next (12)
- next! (12)
- oct (12)
- of (22)
- ord (12)
- pack (21)
- parameters (7)
- parse (10)
-
parse
_ file (10) - partition (12)
- path (87)
- pause (7)
-
post
_ match (12) -
pre
_ match (12) - pread (8)
- prepend (21)
- private (12)
-
private
_ instance _ methods (12) -
private
_ method _ defined? (12) -
protected
_ method _ defined? (12) - public (12)
-
public
_ method _ defined? (12) - putback (24)
- pwd (12)
- pwrite (8)
- quote (12)
- raise (18)
-
raised
_ exception (12) -
raw
_ seed (2) - read (24)
- readchar (12)
- readline (12)
- readlines (84)
- readlink (12)
- realpath (12)
- replace (12)
- replacement (12)
- replacement= (12)
- result (12)
-
return
_ value (12) - reverse (12)
- reverse! (12)
- rindex (12)
- rjust (12)
- rpartition (12)
- rstrip (12)
- rstrip! (12)
- scan (24)
- scrub (36)
- scrub! (36)
- select (24)
- self (12)
-
set
_ backtrace (12) -
set
_ trace _ func (24) - setbyte (12)
- setproctitle (12)
- signm (12)
-
singleton
_ methods (12) - size (24)
- slice (72)
- slice! (72)
- source (12)
-
source
_ location (43) - split (31)
- sprintf (12)
- squeeze (12)
- squeeze! (12)
- start (12)
-
start
_ with? (12) - store (12)
- stress= (12)
- strftime (12)
- string (12)
- strip (12)
- strip! (12)
- sub (60)
- sub! (36)
- subtract (3)
- succ (12)
- succ! (12)
- sum (12)
- swapcase (12)
- swapcase! (12)
- syswrite (12)
-
to
_ a (55) -
to
_ binary (10) -
to
_ c (12) -
to
_ f (12) -
to
_ h (19) -
to
_ i (12) -
to
_ path (27) -
to
_ r (12) -
to
_ s (301) -
to
_ str (24) -
to
_ sym (12) -
tr
_ s (12) -
tr
_ s! (12) - trace (12)
-
trace
_ var (36) - transfer (4)
-
transform
_ keys (20) -
transform
_ keys! (20) -
transform
_ values (18) -
transform
_ values! (18) - transpose (12)
- trap (24)
- truncate (72)
- trust (9)
-
try
_ convert (52) -
try
_ lock (12) - type (7)
- undump (8)
-
unicode
_ normalize (11) -
unicode
_ normalize! (11) -
unicode
_ normalized? (11) - unpack (12)
- unpack1 (9)
-
untrace
_ var (12) - untrust (9)
- untrusted? (9)
- upcase (12)
- upcase! (12)
- upto (12)
- urandom (8)
-
valid
_ encoding? (12) - values (12)
-
values
_ at (24) - write (36)
- zone (12)
- | (12)
検索結果
先頭5件
- String
# tr(pattern , replace) -> String - RubyVM
:: AbstractSyntaxTree - RubyVM
:: InstructionSequence . load _ from _ binary _ extra _ data(binary) -> String - RubyVM
:: AbstractSyntaxTree . parse(string) -> RubyVM :: AbstractSyntaxTree :: Node - RubyVM
:: AbstractSyntaxTree . parse(string , keep _ script _ lines: false , error _ tolerant: false , keep _ tokens: false) -> RubyVM :: AbstractSyntaxTree :: Node
-
String
# tr(pattern , replace) -> String (21299.0) -
pattern 文字列に含まれる文字を検索し、 それを replace 文字列の対応する文字に置き換えます。
...pattern 文字列に含まれる文字を検索し、
それを replace 文字列の対応する文字に置き換えます。
pattern の形式は tr(1) と同じです。つまり、
`a-c' は a から c を意味し、"^0-9" のように
文字列の先頭が `^' の場合は指定文字以外......//emlist[例][ruby]{
p "foo".tr("f", "X") # => "Xoo"
p "foo".tr('a-z', 'A-Z') # => "FOO"
p "FOO".tr('A-Z', 'a-z') # => "foo"
# シーザー暗号の復号
p "ORYV".tr("A-Z", "D-ZA-C") # => "RUBY"
# 全角英数字といくつかの記号の半角化
email = "ruby−lang@......example.com"
p email.tr("0-9a-zA-Z.@−", "0-9a-zA-Z.@-")
# => "ruby-lang@example.com"
//}
@see String#tr!, String#tr_s... -
RubyVM
:: AbstractSyntaxTree (18034.0) -
Ruby のコードをパースして得られる抽象構文木を扱うモジュールです。
...Ruby のコードをパースして得られる抽象構文木を扱うモジュールです。
抽象構文木はRubyVM::AbstractSyntaxTree::Nodeクラスのインスタンスとして表されます。
このモジュールはMRIの抽象構文木の実装の詳細を表します。
このモ......し安定したAPIやMRI以外の実装で抽象構文木を扱いたい場合、
parser gem (https://github.com/whitequark/parser)や
Ripperの使用を検討してください。
もし RubyVM::AbstractSyntaxTree のAPIを安定にしたい場合、14844 での議論に参加してください。... -
RubyVM
:: InstructionSequence . load _ from _ binary _ extra _ data(binary) -> String (15214.0) -
バイナリフォーマットの文字列から埋め込まれたextra_dataを取り出します。
...ら埋め込まれたextra_dataを取り出します。
//emlist[例][ruby]{
iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
binary = iseq.to_binary("extra_data")
RubyVM::InstructionSequence.load_from_binary_extra_data(binary) # => extra_data
//}
@see RubyVM::InstructionSequence#to_binar... -
RubyVM
:: AbstractSyntaxTree . parse(string) -> RubyVM :: AbstractSyntaxTree :: Node (12538.0) -
文字列を抽象構文木にパースし、その木の根ノードを返します。
...ノードを返します。
@param string パースする対象の Ruby のコードを文字列で指定します。
@raise SyntaxError string が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.parse("x = 1 + 2")
# => (SCOPE@1:......す。
@param string パースする対象の Ruby のコードを文字列で指定します。
@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定す......t true を指定すると、構文エラーが発生した際にエラー箇所を type が :ERROR であるようなノードに置き換えてツリーを生成します。
@raise SyntaxError string が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp Ruby......VM::AbstractSyntaxTree.parse("x = 1 + 2")
# => (SCOPE@1:0-1:9
# tbl: [:x]
# args: nil
# body:
# (LASGN@1:0-1:9 :x
# (OPCALL@1:4-1:9 (LIT@1:4-1:5 1) :+ (LIST@1:8-1:9 (LIT@1:8-1:9 2) nil))))
pp RubyVM::AbstractSyntaxTree.parse("x = 1; p(x; y=2", error_tolerant: true)
# => (... -
RubyVM
:: AbstractSyntaxTree . parse(string , keep _ script _ lines: false , error _ tolerant: false , keep _ tokens: false) -> RubyVM :: AbstractSyntaxTree :: Node (12538.0) -
文字列を抽象構文木にパースし、その木の根ノードを返します。
...す。
@param string パースする対象の Ruby のコードを文字列で指定します。
@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定す......t true を指定すると、構文エラーが発生した際にエラー箇所を type が :ERROR であるようなノードに置き換えてツリーを生成します。
@raise SyntaxError string が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp Ruby......VM::AbstractSyntaxTree.parse("x = 1 + 2")
# => (SCOPE@1:0-1:9
# tbl: [:x]
# args: nil
# body:
# (LASGN@1:0-1:9 :x
# (OPCALL@1:4-1:9 (LIT@1:4-1:5 1) :+ (LIST@1:8-1:9 (LIT@1:8-1:9 2) nil))))
pp RubyVM::AbstractSyntaxTree.parse("x = 1; p(x; y=2", error_tolerant: true)
# => (... -
RubyVM
:: AbstractSyntaxTree . parse _ file(pathname) -> RubyVM :: AbstractSyntaxTree :: Node (12426.0) -
pathname のファイルを読み込み、その内容を抽象構文木にパースし、その木の根ノードを返します。
...イルパスを指定します
@raise SyntaxError pathname から取得された文字列が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.parse_file(__FILE__)
# => (SCOPE@1:0-1:50
# tbl: []
# args: nil
# body:
#......(FCALL@1:0-1:50 :pp
# (LIST@1:3-1:50
# (CALL@1:3-1:50
# (COLON2@1:3-1:29 (CONST@1:3-1:9 :RubyVM) :AbstractSyntaxTree)
# :parse_file (LIST@1:41-1:49 (STR@1:41-1:49 "") nil)) nil)))
//}......@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定すると、 Node#token が利用できます。
@param error_tolerant true を指定すると、構......ツリーを生成します。
@raise SyntaxError pathname から取得された文字列が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.parse_file(__FILE__)
# => (SCOPE@1:0-1:50
# tbl: []
# args: nil
# body:
#... -
RubyVM
:: AbstractSyntaxTree . parse _ file(pathname , keep _ script _ lines: false , error _ tolerant: false , keep _ tokens: false) -> RubyVM :: AbstractSyntaxTree :: Node (12426.0) -
pathname のファイルを読み込み、その内容を抽象構文木にパースし、その木の根ノードを返します。
...@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定すると、 Node#token が利用できます。
@param error_tolerant true を指定すると、構......ツリーを生成します。
@raise SyntaxError pathname から取得された文字列が Ruby のコードとして正しくない場合に発生します。
//emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.parse_file(__FILE__)
# => (SCOPE@1:0-1:50
# tbl: []
# args: nil
# body:
#......(FCALL@1:0-1:50 :pp
# (LIST@1:3-1:50
# (CALL@1:3-1:50
# (COLON2@1:3-1:29 (CONST@1:3-1:9 :RubyVM) :AbstractSyntaxTree)
# :parse_file (LIST@1:41-1:49 (STR@1:41-1:49 "") nil)) nil)))
//}... -
RubyVM
:: AbstractSyntaxTree . of(proc) -> RubyVM :: AbstractSyntaxTree :: Node (12414.0) -
引数 proc に渡したProcやメソッドオブジェクトの抽象構文木を返します。
...emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.of(proc {1 + 2})
# => (SCOPE@2:38-2:45
# tbl: []
# args: nil
# body:
# (OPCALL@2:39-2:44 (LIT@2:39-2:40 1) :+
# (LIST@2:43-2:44 (LIT@2:43-2:44 2) nil)))
def hello
puts "hello, world"
end
pp RubyVM::AbstractSyntaxTree.of(met......pre_num: 0
# pre_init: nil
# opt: nil
# first_post: nil
# post_num: 0
# post_init: nil
# rest: nil
# kw: nil
# kwrest: nil
# block: nil)
# body:
# (FCALL@6:2-6:21 :puts (LIST@6:7-6:21 (STR@6:7-6:21 "hello, world") nil)))
//}......@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定すると、 Node#token が利用できます。
@param error_tolerant true を指定すると、構... -
RubyVM
:: AbstractSyntaxTree . of(proc , keep _ script _ lines: false , error _ tolerant: false , keep _ tokens: false) -> RubyVM :: AbstractSyntaxTree :: Node (12414.0) -
引数 proc に渡したProcやメソッドオブジェクトの抽象構文木を返します。
...@param keep_script_lines true を指定すると、 Node#script_lines でノードと関連づけられたソースコードのテキストを取得できます。
@param keep_tokens true を指定すると、 Node#token が利用できます。
@param error_tolerant true を指定すると、構......emlist[][ruby]{
pp RubyVM::AbstractSyntaxTree.of(proc {1 + 2})
# => (SCOPE@2:38-2:45
# tbl: []
# args: nil
# body:
# (OPCALL@2:39-2:44 (LIT@2:39-2:40 1) :+
# (LIST@2:43-2:44 (LIT@2:43-2:44 2) nil)))
def hello
puts "hello, world"
end
pp RubyVM::AbstractSyntaxTree.of(met......pre_num: 0
# pre_init: nil
# opt: nil
# first_post: nil
# post_num: 0
# post_init: nil
# rest: nil
# kw: nil
# kwrest: nil
# block: nil)
# body:
# (FCALL@6:2-6:21 :puts (LIST@6:7-6:21 (STR@6:7-6:21 "hello, world") nil)))
//}... -
Object
:: RUBY _ ENGINE -> String (12408.0) -
Ruby処理系実装の種類を表す文字列。
...Ruby処理系実装の種類を表す文字列。
例:
$ ruby-1.9.1 -ve 'p RUBY_ENGINE'
ruby 1.9.1p0 (2009-03-04 revision 22762) [x86_64-linux]
"ruby"
$ jruby -ve 'p RUBY_ENGINE'
jruby 1.2.0 (ruby 1.8.6 patchlevel 287) (2009-03-16 rev 9419) [i386-java]
"jruby"... -
Object
:: RUBY _ DESCRIPTION -> String (12348.0) -
Ruby の詳細を表す文字列。
...Ruby の詳細を表す文字列。
ruby -v で表示される内容が格納されています。... -
Object
:: RUBY _ VERSION -> String (12348.0) -
Ruby のバージョンを表す文字列。
...
Ruby のバージョンを表す文字列。
Ruby のバージョンは、major.minor.teeny という形式です。... -
Object
:: RUBY _ COPYRIGHT -> String (12336.0) -
Ruby のコピーライトを表す文字列。
...Ruby のコピーライトを表す文字列。...