mirror of
https://github.com/ruby/ruby.git
synced 2025-08-28 15:36:16 +02:00
* vm_trace.c (rb_tracepoint_attr_method_id):
rename TracePoint#id to TracePoint#method_id. * include/ruby/debug.h: ditto. * test/ruby/test_settracefunc.rb: ditto, git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37973 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
89c889d4e7
commit
479e396192
4 changed files with 16 additions and 7 deletions
|
@ -418,7 +418,7 @@ class TestSetTraceFunc < Test::Unit::TestCase
|
|||
|
||||
eval <<-EOF.gsub(/^.*?: /, ""), nil, 'xyzzy'
|
||||
1: trace = TracePoint.trace(*trace_events){|tp|
|
||||
2: events << [tp.event, tp.lineno, tp.path, tp.defined_class, tp.id, tp.self, tp.binding.eval("local_var"), get_data.(tp)]
|
||||
2: events << [tp.event, tp.lineno, tp.path, tp.defined_class, tp.method_id, tp.self, tp.binding.eval("local_var"), get_data.(tp)]
|
||||
3: }
|
||||
4: 1.times{|;local_var| local_var = :inner
|
||||
5: tap{}
|
||||
|
@ -587,7 +587,7 @@ class TestSetTraceFunc < Test::Unit::TestCase
|
|||
assert_raise(RuntimeError){tp_store.lineno}
|
||||
assert_raise(RuntimeError){tp_store.event}
|
||||
assert_raise(RuntimeError){tp_store.path}
|
||||
assert_raise(RuntimeError){tp_store.id}
|
||||
assert_raise(RuntimeError){tp_store.method_id}
|
||||
assert_raise(RuntimeError){tp_store.defined_class}
|
||||
assert_raise(RuntimeError){tp_store.binding}
|
||||
assert_raise(RuntimeError){tp_store.self}
|
||||
|
@ -601,7 +601,7 @@ class TestSetTraceFunc < Test::Unit::TestCase
|
|||
def test_tracepoint_enable
|
||||
ary = []
|
||||
trace = TracePoint.new(:call){|tp|
|
||||
ary << tp.id
|
||||
ary << tp.method_id
|
||||
}
|
||||
foo
|
||||
trace.enable{
|
||||
|
@ -614,7 +614,7 @@ class TestSetTraceFunc < Test::Unit::TestCase
|
|||
def test_tracepoint_disable
|
||||
ary = []
|
||||
trace = TracePoint.trace(:call){|tp|
|
||||
ary << tp.id
|
||||
ary << tp.method_id
|
||||
}
|
||||
foo
|
||||
trace.disable{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue