るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.075秒)
トップページ > クエリ:Kernel.#String[x] > クエリ:to_r[x] > クエリ:write[x] > クラス:Thread::Backtrace::Location[x]

別のキーワード

  1. _builtin to_s
  2. openssl to_der
  3. openssl to_s
  4. _builtin to_a
  5. openssl to_pem

ライブラリ

検索結果

Thread::Backtrace::Location#to_s -> String (118.0)

self が表すフレームを Kernel.#caller と同じ表現にした文字列を返し ます。

...self が表すフレームを Kernel.#caller と同じ表現にした文字列を返し
ます。

//emlist[例][ruby]{
# foo.rb
class Foo
attr_accessor :locations
def initialize(skip)
@locations = caller_locations(skip)
end
end

Foo.new(0..2).locations.map do |call|
puts call.to_s
end...