ÿØÿà JFIF    ÿÛ „  ( %!1!%)+//.383,7(-.+  -%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ     ÿÄ J    ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ   ÿÄ *  !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú "SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5 ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍѶ¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e ríV ?> ......................................... ............................................................................. ÿØÿà JFIF    ÿÛ „  ( %!1!%)+//.383,7(-.+  -%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ     ÿÄ J    ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ   ÿÄ *  !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú "SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5 ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍѶ¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e ríV ?> ......................................... ............................................................................. ???????????????????????????????????? ???????????????????????????????????? ÿØÿà JFIF    ÿÛ „  ( %!1!%)+//.383,7(-.+  -%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ     ÿÄ J    ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ   ÿÄ *  !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú "SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5 ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍѶ¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e ríV ?> ......................................... ............................................................................. ÿØÿà JFIF    ÿÛ „  ( %!1!%)+//.383,7(-.+  -%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ     ÿÄ J    ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ   ÿÄ *  !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú "SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5 ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍѶ¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e ríV ?> ......................................... ............................................................................. ???????????????????????????????????? ???????????????????????????????????? U:RDoc::AnyMethod[iI"allow_reentry:ETI"TracePoint::allow_reentry;TT: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [ I"8Generally, while a TracePoint callback is running, ;TI"8other registered callbacks are not called to avoid ;TI" confusion from reentrance. ;TI"9This method allows reentrance within a given block. ;TI"EUse this method carefully to avoid infinite callback invocation.;To:RDoc::Markup::BlankLineo; ; [I"3If called when reentrance is already allowed, ;TI"it raises a RuntimeError.;T@o; ; [I"Example:;T@o:RDoc::Markup::Verbatim; [+I"# Without reentry ;TI"# --------------- ;TI" ;TI"2line_handler = TracePoint.new(:line) do |tp| ;TI"= next if tp.path != __FILE__ # Only works in this file ;TI" puts "Line handler" ;TI"$ binding.eval("class C; end") ;TI"end.enable ;TI" ;TI"4class_handler = TracePoint.new(:class) do |tp| ;TI" puts "Class handler" ;TI"end.enable ;TI" ;TI" class B ;TI" end ;TI" ;TI"O# This script will print "Class handler" only once: when inside the :line ;TI"0# handler, all other handlers are ignored. ;TI" ;TI"# With reentry ;TI"# ------------ ;TI" ;TI"2line_handler = TracePoint.new(:line) do |tp| ;TI"= next if tp.path != __FILE__ # Only works in this file ;TI"Q next if (__LINE__..__LINE__+3).cover?(tp.lineno) # Prevent infinite calls ;TI" puts "Line handler" ;TI"A TracePoint.allow_reentry { binding.eval("class C; end") } ;TI"end.enable ;TI" ;TI"4class_handler = TracePoint.new(:class) do |tp| ;TI" puts "Class handler" ;TI"end.enable ;TI" ;TI" class B ;TI" end ;TI" ;TI"Z# This will print "Class handler" twice: inside the allow_reentry block in the :line ;TI",# handler, other handlers are enabled. ;T: @format0o; ; [ I"MNote that the example shows the principal effect of the method, but its ;TI"Xpractical usage is for debugging libraries that sometimes require other libraries' ;TI"Qhooks to not be affected by the debugger being inside trace point handling. ;TI"IPrecautions should be taken against infinite recursion in this case ;TI"P(note that we needed to filter out calls by itself from the :line handler, ;TI"0otherwise it would call itself infinitely).;T: @fileI"trace_point.rb;T:0@omit_headings_from_table_of_contents_below0I"(TracePoint.allow_reentry { block } ;T0[I"();T@JFI"TracePoint;TcRDoc::NormalClass00