るりまサーチ

最速Rubyリファレンスマニュアル検索!
11件ヒット [1-11件を表示] (0.060秒)
トップページ > クエリ:-[x] > クエリ:on[x] > クエリ:allocation_sourcefile[x]

別のキーワード

  1. optionparser on
  2. optparse on
  3. tracer on
  4. thread abort_on_exception
  5. _builtin abort_on_exception

ライブラリ

モジュール

検索結果

ObjectSpace.#allocation_sourcefile(object) -> String (24307.0)

objectの元となったソースファイル名を返します。

...uire 'objspace'

ObjectSpace::trace_object_allocations_start
obj = Object.new
puts "file:#{ObjectSpace::allocation_sourcefile(obj)}" # => file:test.rb
ObjectSpace::trace_object_allocations_stop
//}

@see ObjectSpace.#trace_object_allocations_start,
ObjectSpace.#trace_object_allocations_stop...