Actions
Bug #9357
closedTracePoint's c_return traces return from call to 'trace'
Description
=begin
Hello,
In TracePoint, trace on 'c_call' doesn't trace the call made to 'trace' method, where as trace on 'c_return' does, is this expected behaviour?
Here's the code I used to reproduce it:
=== Code (c_return)
class Car
def self.start
print "Started..."
end
end
TracePoint.trace(:c_return) do |tp|
puts "'#{tp.event}' event occurred in #{tp.defined_class}##{tp.method_id}"
end
Car.start
=== Env
Ruby 2.1.0
=== Actual output
'c_return' event occurred in #<Class:TracePoint>#trace
Started...'c_return' event occurred in IO#write
'c_return' event occurred in Kernel#print
=== Expected output
Started...'c_return' event occurred in IO#write
'c_return' event occurred in Kernel#print
=== Code on eval.in
Here's the link to code on eval.in:
Thanks.
Actions
Like0
Like0Like0Like0Like0Like0