るりまサーチ

最速Rubyリファレンスマニュアル検索!
221件ヒット [101-200件を表示] (0.043秒)

別のキーワード

  1. rexml instruction
  2. instruction ==
  3. instruction new
  4. instruction clone
  5. instruction target

検索結果

<< < 1 2 3 > >>

RubyVM::InstructionSequence#base_label -> String (3007.0)

self が表す命令シーケンスの基本ラベルを返します。

...返します。

例1:irb で実行した場合

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
# => <RubyVM::InstructionSequence:<compiled>@<compiled>>
iseq.base_label
# => "<compiled>"

例2: RubyVM::InstructionSequence.compile_file を使用した場合

# /tmp/method.rb
de...
...# irb
> iseq = RubyVM::InstructionSequence.compile_file('/tmp/method.rb')
> iseq.base_label # => "<main>"

例3:

# /tmp/method2.rb
def hello
puts "hello, world"
end

RubyVM::InstructionSequence.of(method(:hello)).base_label
# => "hello"

@
see RubyVM::InstructionSequence#label...

RubyVM::InstructionSequence#disasm -> String (3007.0)

self が表す命令シーケンスを人間が読める形式の文字列に変換して返します。

...ケンスを人間が読める形式の文字列に変換して返します。

puts RubyVM::InstructionSequence.compile('1 + 2').disasm

出力:

== disasm: <RubyVM::InstructionSequence:<compiled>@<compiled>>==========
0000 trace 1 (...
...1)
0002 putobject 1
0004 putobject 2
0006 opt_plus <ic:1>
0008 leave

@
see RubyVM::InstructionSequence.disasm...

RubyVM::InstructionSequence#disassemble -> String (3007.0)

self が表す命令シーケンスを人間が読める形式の文字列に変換して返します。

...ケンスを人間が読める形式の文字列に変換して返します。

puts RubyVM::InstructionSequence.compile('1 + 2').disasm

出力:

== disasm: <RubyVM::InstructionSequence:<compiled>@<compiled>>==========
0000 trace 1 (...
...1)
0002 putobject 1
0004 putobject 2
0006 opt_plus <ic:1>
0008 leave

@
see RubyVM::InstructionSequence.disasm...

RubyVM::InstructionSequence#inspect -> String (3007.0)

self の情報をラベルとパスを含んだ人間に読みやすい文字列にして返します。

...んだ人間に読みやすい文字列にして返します。

//emlist[例][ruby]{
iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
iseq.inspect # => "<RubyVM::InstructionSequence:<compiled>@<compiled>>"
//}

@
see RubyVM::InstructionSequence#label,
RubyVM::InstructionSequence#path...

RubyVM::InstructionSequence#label -> String (3007.0)

self が表す命令シーケンスのラベルを返します。通常、メソッド名、クラス名、 モジュール名などで構成されます。

...を返します。

例1:irb で実行した場合

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
# => <RubyVM::InstructionSequence:<compiled>@<compiled>>
iseq.label
# => "<compiled>"

例2: RubyVM::InstructionSequence.compile_file を使用した場合

# /tmp/method.rb
def...
...end

# irb
> iseq = RubyVM::InstructionSequence.compile_file('/tmp/method.rb')
> iseq.label # => "<main>"

例3:

# /tmp/method2.rb
def hello
puts "hello, world"
end

RubyVM::InstructionSequence.of(method(:hello)).label
# => "hello"

@
see RubyVM::InstructionSequence#base_label...

絞り込み条件を変える

RubyVM::InstructionSequence#path -> String (3007.0)

self が表す命令シーケンスの相対パスを返します。

...を返します。

例1:irb で実行した場合

iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
# => <RubyVM::InstructionSequence:<compiled>@<compiled>>
iseq.path
# => "<compiled>"

例2: RubyVM::InstructionSequence.compile_file を使用した場合

# /tmp/method.rb
def...
...hello
puts "hello, world"
end

# irb
> iseq = RubyVM::InstructionSequence.compile_file('method.rb')
> iseq.path # => "method.rb"

@
see RubyVM::InstructionSequence#absolute_path...

REXML::Parsers::SAX2Parser#listen(ary) { ... } -> () (31.0)

コールバックをパーサに登録します。

...2Listener#end_prefix_mapping)
* :characters (文字データ, REXML::SAX2Listener#characters)
* :processing_instruction
(XML 処理命令 REXML::SAX2Listener#processing_instruction)
* :doctype
(DTD, REXML::SAX2Listener#doctype)
* :attlistdecl
(DTDの属性リスト宣言, REXML::...
...れる名前は QName、つまり prefix を含む文字列です。

@
param sym イベント名(シンボル)
@
param ary 要素名によるコールバック呼び出し条件の指定(文字列もしくは正規表現の配列)
@
param listener コールバックオブジェクト

=== 例
# CDAT...

REXML::Parsers::SAX2Parser#listen(ary, listener) -> () (31.0)

コールバックをパーサに登録します。

...2Listener#end_prefix_mapping)
* :characters (文字データ, REXML::SAX2Listener#characters)
* :processing_instruction
(XML 処理命令 REXML::SAX2Listener#processing_instruction)
* :doctype
(DTD, REXML::SAX2Listener#doctype)
* :attlistdecl
(DTDの属性リスト宣言, REXML::...
...れる名前は QName、つまり prefix を含む文字列です。

@
param sym イベント名(シンボル)
@
param ary 要素名によるコールバック呼び出し条件の指定(文字列もしくは正規表現の配列)
@
param listener コールバックオブジェクト

=== 例
# CDAT...

REXML::Parsers::SAX2Parser#listen(listener) -> () (31.0)

コールバックをパーサに登録します。

...2Listener#end_prefix_mapping)
* :characters (文字データ, REXML::SAX2Listener#characters)
* :processing_instruction
(XML 処理命令 REXML::SAX2Listener#processing_instruction)
* :doctype
(DTD, REXML::SAX2Listener#doctype)
* :attlistdecl
(DTDの属性リスト宣言, REXML::...
...れる名前は QName、つまり prefix を含む文字列です。

@
param sym イベント名(シンボル)
@
param ary 要素名によるコールバック呼び出し条件の指定(文字列もしくは正規表現の配列)
@
param listener コールバックオブジェクト

=== 例
# CDAT...

REXML::Parsers::SAX2Parser#listen(sym) { ... } -> () (31.0)

コールバックをパーサに登録します。

...2Listener#end_prefix_mapping)
* :characters (文字データ, REXML::SAX2Listener#characters)
* :processing_instruction
(XML 処理命令 REXML::SAX2Listener#processing_instruction)
* :doctype
(DTD, REXML::SAX2Listener#doctype)
* :attlistdecl
(DTDの属性リスト宣言, REXML::...
...れる名前は QName、つまり prefix を含む文字列です。

@
param sym イベント名(シンボル)
@
param ary 要素名によるコールバック呼び出し条件の指定(文字列もしくは正規表現の配列)
@
param listener コールバックオブジェクト

=== 例
# CDAT...

絞り込み条件を変える

<< < 1 2 3 > >>