ruby-changes:30334
From: zzak <ko1@a...>
Date: Mon, 5 Aug 2013 22:25:19 +0900 (JST)
Subject: [ruby-changes:30334] zzak:r42386 (trunk): * vm_trace.c: [DOC] Fix TracePoint return values in examples
zzak 2013-08-05 22:25:02 +0900 (Mon, 05 Aug 2013) New Revision: 42386 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=42386 Log: * vm_trace.c: [DOC] Fix TracePoint return values in examples Based on a patch by @sho-h [Fixes GH-373] https://github.com/ruby/ruby/pull/373 Modified files: trunk/ChangeLog trunk/vm_trace.c Index: ChangeLog =================================================================== --- ChangeLog (revision 42385) +++ ChangeLog (revision 42386) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Mon Aug 5 22:23:59 2013 Zachary Scott <e@z...> + + * vm_trace.c: [DOC] Fix TracePoint return values in examples + Based on a patch by @sho-h [Fixes GH-373] + https://github.com/ruby/ruby/pull/373 + Mon Aug 5 17:38:15 2013 Nobuyoshi Nakada <nobu@r...> * win32/win32.c (rb_w32_write_console): use MultiByteToWideChar() for Index: vm_trace.c =================================================================== --- vm_trace.c (revision 42385) +++ vm_trace.c (revision 42386) @@ -1159,10 +1159,10 @@ rb_tracepoint_new(VALUE target_thval, rb https://github.com/ruby/ruby/blob/trunk/vm_trace.c#L1159 * trace = TracePoint.new(:call) do |tp| * p [tp.lineno, tp.defined_class, tp.method_id, tp.event] * end - * #=> #<TracePoint:0x007f17372cdb20> + * #=> #<TracePoint:disabled> * * trace.enable - * #=> #<TracePoint:0x007f17372cdb20> + * #=> false * * puts "Hello, TracePoint!" * # ... @@ -1302,10 +1302,10 @@ Init_vm_trace(void) https://github.com/ruby/ruby/blob/trunk/vm_trace.c#L1302 * trace = TracePoint.new(:raise) do |tp| * p [tp.lineno, tp.event, tp.raised_exception] * end - * #=> #<TracePoint:0x007f786a452448> + * #=> #<TracePoint:disabled> * * trace.enable - * #=> #<TracePoint:0x007f786a452448> + * #=> false * * 0 / 0 * #=> [5, :raise, #<ZeroDivisionError: divided by 0>] @@ -1349,7 +1349,7 @@ Init_vm_trace(void) https://github.com/ruby/ruby/blob/trunk/vm_trace.c#L1349 * automatically. * * trace = TracePoint.trace(:call) { |tp| [tp.lineno, tp.event] } - * #=> #<TracePoint:0x007f786a452448> + * #=> #<TracePoint:enabled> * * trace.enabled? #=> true */ -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/