Forum: Ruby-dev [ruby-trunk - Bug #6301][Open] irb 起動後に conf.debug level を変更するとエラーになる

Posted by sho-h (Sho Hashimoto) (Guest)
on 2012-04-15 18:44
(Received via mailing list)
Issue #6301 has been reported by sho-h (Sho Hashimoto).

----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301

Author: sho-h (Sho Hashimoto)
Status: Open
Priority: Normal
Assignee:
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Posted by ayumin (Ayumu AIZAWA) (Guest)
on 2012-04-15 19:42
(Received via mailing list)
Issue #6301 has been updated by ayumin (Ayumu AIZAWA).

Assignee set to keiju (Keiju Ishitsuka)


----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301#change-25914

Author: sho-h (Sho Hashimoto)
Status: Open
Priority: Normal
Assignee: keiju (Keiju Ishitsuka)
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Posted by sho-h (Sho Hashimoto) (Guest)
on 2012-04-16 16:39
(Received via mailing list)
Issue #6301 has been updated by sho-h (Sho Hashimoto).

File irb_debug_level.patch added

すみません。昨日は気づきませんでしたが、conf.debug_level は irb の起動後に再度代入するまでは効いていないようでした。

$ irb
> RubyLex.debug_level
 => 0
> conf.debug_level
 => 1
> conf.debug_level = 1
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='
        ...(省略)...

> conf.debug_level
MATCH: start : #<RubyLex:0x00000000f613a0 ...(省略)...
 => 1

> RubyLex.debug_level
MATCH: start : #<RubyLex:0x00000001a85470 ...(省略)...
 => 1

昨日の提案の修正に加えて以下が必要なのではないかと思いました。

* IRB.conf[:DEBUG_LEVEL] のデフォルト値を 0 に揃える(現状の実際の動作を維持)
* lib/irb/init.rb で conf.debug_level の値を反映させる

----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301#change-25938

Author: sho-h (Sho Hashimoto)
Status: Open
Priority: Normal
Assignee: keiju (Keiju Ishitsuka)
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Posted by mame (Yusuke Endoh) (Guest)
on 2012-04-17 14:22
(Received via mailing list)
Issue #6301 has been updated by mame (Yusuke Endoh).

Status changed from Open to Assigned


----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301#change-25966

Author: sho-h (Sho Hashimoto)
Status: Assigned
Priority: Normal
Assignee: keiju (Keiju Ishitsuka)
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Posted by Heesob Park (phasis)
on 2012-12-26 04:12
(Received via mailing list)
Issue #6301 has been updated by phasis68 (Heesob Park).


After the changeset r38611, the output of irb is too verbose by default.

C:\Users\phasis>irb
<SLex: @head = #<IRB::SLex::Node:0x00000002ea62b0 
@Tree={"\0"=>#<IRB::SLex::Node:0x00000002ea5e50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u0004"=>#<IRB::SLex::Node:0x00000002ea5928 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u001A"=>#<IRB::SLex::Node:0x00000002ea5540 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
" "=>#<IRB::SLex::Node:0x00000002ea4e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\t"=>#<IRB::SLex::Node:0x00000002ea4b68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\f"=>#<IRB::SLex::Node:0x00000002ea4668 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\r"=>#<IRB::SLex::Node:0x00000002ea4078 @Tree={}, @preproc=ni
 l, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\v"=>#<IRB::SLex::Node:0x00000002e9feb0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"#"=>#<IRB::SLex::Node:0x00000002e9fbe0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9fdc0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:354>>, 
"="=>#<IRB::SLex::Node:0x00000002e9f618 
@Tree={"b"=>#<IRB::SLex::Node:0x00000002e9f5a0 
@Tree={"e"=>#<IRB::SLex::Node:0x00000002e9f550 
@Tree={"g"=>#<IRB::SLex::Node:0x00000002e9f460 
@Tree={"i"=>#<IRB::SLex::Node:0x00000002e9f410 
@Tree={"n"=>#<IRB::SLex::Node:0x00000002e9f3c0 @Tree={}, 
@preproc=#<Proc:0x00000002e9fb40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>, 
@postproc=#<Proc:0x00000002e9fb18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>, 
"="=>#<IRB::SLex::Node:0x00000002e9d9a8 @Tree={"="=>#<I
 RB::SLex::Node:0x00000002e9d660 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e9d1b0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"\n"=>#<IRB::SLex::Node:0x00000002e9ecb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9efd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:371>>, 
"*"=>#<IRB::SLex::Node:0x00000002e9e4c0 
@Tree={"*"=>#<IRB::SLex::Node:0x00000002e9e010 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8d4e0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"="=>#<IRB::SLex::Node:0x00000002e8d850 @Tree={}
 , @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e9cc38 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e9cb98 
@Tree={">"=>#<IRB::SLex::Node:0x00000002e9cb20 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e94790 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86f28 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e949e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:406>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e96158 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e95820 @Tre
 e={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e955a0 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e869d8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"!"=>#<IRB::SLex::Node:0x00000002e95230 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e94ec0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e94b00 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"'"=>#<IRB::SLex::Node:0x00000002e94268 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00
 000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"\""=>#<IRB::SLex::Node:0x00000002e8ed18 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"`"=>#<IRB::SLex::Node:0x00000002e8fc68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8ff10@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:433>>, 
"?"=>#<IRB::SLex::Node:0x00000002e8f8d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8fb00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:443>>, 
"&"=>#<IRB::SLex::Node:0x00000002e8f560 
@Tree={"&"=>#<IRB::SLex::Node:0x00000002e8f178 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e85b50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8d030 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, @postproc=#<
 Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"|"=>#<IRB::SLex::Node:0x00000002e8ee30 
@Tree={"|"=>#<IRB::SLex::Node:0x00000002e8e750 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86460 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8c1a8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"+"=>#<IRB::SLex::Node:0x00000002e8de90 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8de40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e852b8 @Tree={}, 
@preproc=#<Proc:0x00000002e85768@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:478>, 
@postproc=#<Proc:0x00000002e85740@c:/
 usr/lib/ruby/2.0.0/irb/ruby-lex.rb:478>>}, @preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"-"=>#<IRB::SLex::Node:0x00000002e8db98 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8db48 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e84ed0 @Tree={}, 
@preproc=#<Proc:0x00000002e851a0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>, 
@postproc=#<Proc:0x00000002e85150@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"^"=>#<IRB::SLex::Node:0x00000002e87298 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e876d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7e120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:578>>, 
"."=>#<IRB::SLex::Node:0x00000002e7fd68 
@Tree={"."=>#<IRB::SLex::Node:0x0000000
 2e7f930 @Tree={"."=>#<IRB::SLex::Node:0x00000002e7f548 @Tree={}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7ff20@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:508>>, 
"]"=>#<IRB::SLex::Node:0x00000002e7f0e8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
"}"=>#<IRB::SLex::Node:0x00000002e7ee40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
")"=>#<IRB::SLex::Node:0x00000002e7eb98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
":"=>#<IRB::SLex::Node:0x00000002e7e8a0 
@Tree={":"=>#<IRB::SLex::Node:0x00000002e7e558 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e7d8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:550>>}, 
@preproc=nil, @postproc
 =#<Proc:0x00000002e7ead0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:539>>, 
"/"=>#<IRB::SLex::Node:0x00000002e7e238 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e490@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:562>>, 
","=>#<IRB::SLex::Node:0x00000002e7dbd0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7ddd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:589>>, 
";"=>#<IRB::SLex::Node:0x00000002e7d810 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7da40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:595>>, 
"~"=>#<IRB::SLex::Node:0x00000002e7d540 
@Tree={"@"=>#<IRB::SLex::Node:0x00000002e7d0e0 @Tree={}, 
@preproc=#<Proc:0x00000002e7d400@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>, 
@postproc=#<Proc:0x00000002e7d388@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7d770@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:606>>, 
"("=>#<IRB::SLex::Node:0x00000002e7cd98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7cfc8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:618>>,
 "["=>#<IRB::SLex::Node:0x00000002e7ca28 
@Tree={"]"=>#<IRB::SLex::Node:0x00000002e7c9d8 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e7c5a0 @Tree={}, 
@preproc=#<Proc:0x00000002e7c898@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>, 
@postproc=#<Proc:0x00000002e7c870@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>>}, 
@preproc=#<Proc:0x00000002e7cc58@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>, 
@postproc=#<Proc:0x00000002e7cc30@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7c4d8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:644>>, 
"{"=>#<IRB::SLex::Node:0x00000002e7c0c8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7c2d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:663>>, 
"\\"=>#<IRB::SLex::Node:0x00000002e77e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77fa0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:676>>, 
"%"=>#<IRB::SLex::Node:0x00000002e77bb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77d70@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:688>>, 
"$"=>#<I
 RB::SLex::Node:0x00000002e77988 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77b18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:703>>, 
"@"=>#<IRB::SLex::Node:0x00000002e776b8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e778e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:708>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e775f0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:728>>>
irb(main):001:0> exit
MATCH: start : #<RubyLex:0x00000002ea63a0 @OP=<SLex: @head = 
#<IRB::SLex::Node:0x00000002ea62b0 
@Tree={"\0"=>#<IRB::SLex::Node:0x00000002ea5e50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u0004"=>#<IRB::SLex::Node:0x00000002ea5928 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u001A"=>#<IRB::SLex::Node:0x00000002ea5540 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
" "=>#<IRB::SLex::Node:0x00000002ea4e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\t"=>#<IRB::SLex::Node:0x00000002ea4b68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\f"=>#<IRB::SLex::Node:0x00000002ea4668 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\r"=>#<IRB::SLe
 x::Node:0x00000002ea4078 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\v"=>#<IRB::SLex::Node:0x00000002e9feb0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"#"=>#<IRB::SLex::Node:0x00000002e9fbe0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9fdc0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:354>>, 
"="=>#<IRB::SLex::Node:0x00000002e9f618 
@Tree={"b"=>#<IRB::SLex::Node:0x00000002e9f5a0 
@Tree={"e"=>#<IRB::SLex::Node:0x00000002e9f550 
@Tree={"g"=>#<IRB::SLex::Node:0x00000002e9f460 
@Tree={"i"=>#<IRB::SLex::Node:0x00000002e9f410 
@Tree={"n"=>#<IRB::SLex::Node:0x00000002e9f3c0 @Tree={}, 
@preproc=#<Proc:0x00000002e9fb40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>, 
@postproc=#<Proc:0x00000002e9fb18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>, "="=>#<IR
 B::SLex::Node:0x00000002e9d9a8 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e9d660 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e9d1b0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"\n"=>#<IRB::SLex::Node:0x00000002e9ecb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9efd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:371>>, 
"*"=>#<IRB::SLex::Node:0x00000002e9e4c0 
@Tree={"*"=>#<IRB::SLex::Node:0x00000002e9e010 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8d4e0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"=
 "=>#<IRB::SLex::Node:0x00000002e8d850 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e9cc38 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e9cb98 
@Tree={">"=>#<IRB::SLex::Node:0x00000002e9cb20 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e94790 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86f28 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e949e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:406>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e96158 @Tree
 ={"="=>#<IRB::SLex::Node:0x00000002e95820 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e955a0 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e869d8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"!"=>#<IRB::SLex::Node:0x00000002e95230 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e94ec0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e94b00 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"'"=>#<IRB::SLex::Node:0x00000002e94268
  @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"\""=>#<IRB::SLex::Node:0x00000002e8ed18 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"`"=>#<IRB::SLex::Node:0x00000002e8fc68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8ff10@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:433>>, 
"?"=>#<IRB::SLex::Node:0x00000002e8f8d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8fb00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:443>>, 
"&"=>#<IRB::SLex::Node:0x00000002e8f560 
@Tree={"&"=>#<IRB::SLex::Node:0x00000002e8f178 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e85b50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8d030 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/
 ruby-lex.rb:471>>}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"|"=>#<IRB::SLex::Node:0x00000002e8ee30 
@Tree={"|"=>#<IRB::SLex::Node:0x00000002e8e750 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86460 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8c1a8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"+"=>#<IRB::SLex::Node:0x00000002e8de90 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8de40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e852b8 @Tree={}, 
@preproc=#<Proc:0x00000002e85768@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.
 rb:478>, 
@postproc=#<Proc:0x00000002e85740@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:478>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"-"=>#<IRB::SLex::Node:0x00000002e8db98 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8db48 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e84ed0 @Tree={}, 
@preproc=#<Proc:0x00000002e851a0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>, 
@postproc=#<Proc:0x00000002e85150@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"^"=>#<IRB::SLex::Node:0x00000002e87298 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e876d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7e120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:578>>, 
"."=>#<IRB::SLex::Node:0x00000002
 e7fd68 @Tree={"."=>#<IRB::SLex::Node:0x00000002e7f930 
@Tree={"."=>#<IRB::SLex::Node:0x00000002e7f548 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7ff20@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:508>>, 
"]"=>#<IRB::SLex::Node:0x00000002e7f0e8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
"}"=>#<IRB::SLex::Node:0x00000002e7ee40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
")"=>#<IRB::SLex::Node:0x00000002e7eb98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
":"=>#<IRB::SLex::Node:0x00000002e7e8a0 
@Tree={":"=>#<IRB::SLex::Node:0x00000002e7e558 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e7d8@c:/usr/lib/ruby/2.0.0/i
 rb/ruby-lex.rb:550>>}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7ead0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:539>>, 
"/"=>#<IRB::SLex::Node:0x00000002e7e238 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e490@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:562>>, 
","=>#<IRB::SLex::Node:0x00000002e7dbd0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7ddd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:589>>, 
";"=>#<IRB::SLex::Node:0x00000002e7d810 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7da40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:595>>, 
"~"=>#<IRB::SLex::Node:0x00000002e7d540 
@Tree={"@"=>#<IRB::SLex::Node:0x00000002e7d0e0 @Tree={}, 
@preproc=#<Proc:0x00000002e7d400@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>, 
@postproc=#<Proc:0x00000002e7d388@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7d770@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:606>>, 
"("=>#<IRB::SLex::Node:0x00000002e7cd98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7cfc8
 @c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:618>>, 
"["=>#<IRB::SLex::Node:0x00000002e7ca28 
@Tree={"]"=>#<IRB::SLex::Node:0x00000002e7c9d8 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e7c5a0 @Tree={}, 
@preproc=#<Proc:0x00000002e7c898@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>, 
@postproc=#<Proc:0x00000002e7c870@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>>}, 
@preproc=#<Proc:0x00000002e7cc58@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>, 
@postproc=#<Proc:0x00000002e7cc30@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7c4d8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:644>>, 
"{"=>#<IRB::SLex::Node:0x00000002e7c0c8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7c2d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:663>>, 
"\\"=>#<IRB::SLex::Node:0x00000002e77e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77fa0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:676>>, 
"%"=>#<IRB::SLex::Node:0x00000002e77bb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77d70@c:/usr/
 lib/ruby/2.0.0/irb/ruby-lex.rb:688>>, 
"$"=>#<IRB::SLex::Node:0x00000002e77988 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77b18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:703>>, 
"@"=>#<IRB::SLex::Node:0x00000002e776b8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e778e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:708>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e775f0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:728>>>, 
@io=#<IRB::StdioInputMethod:0x00000003009828 @file_name="(line)", 
@line_no=1, @line=[nil, "exit\n"], @stdin=#<IO:fd 0>, @stdout=#<IO:fd 
1>, @prompt="irb(main):001:0> ">, 
@input=#<Proc:0x0000000291b520@c:/usr/lib/ruby/2.0.0/irb.rb:457>, 
@seek=0, @line_no=1, @exp_line_no=1, @base_char_no=0, @char_no=0, 
@rests=["e", "x", "i", "t", "\n"], @readed=[], @here_readed=[], 
@indent=0, @indent_stack=[], @lex_state=:EXPR_BEG, @space_seen=false, 
@here_header=false, @continue=false, @line="", @skip_space=false, 
@readed_auto_clean_up=false, @exception_on_syntax_error=false, @prom
 pt=#<Proc:0x0000000291b548@c:/usr/lib/ruby/2.0.0/irb.rb:430>, 
@ltype=nil, @quoted=nil, @prev_seek=0, @prev_line_no=1, @prev_char_no=0>
:e::x::i::t:exit
MATCH: end : #<RubyLex:0x00000002ea63a0 @OP=<SLex: @head = 
#<IRB::SLex::Node:0x00000002ea62b0 
@Tree={"\0"=>#<IRB::SLex::Node:0x00000002ea5e50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u0004"=>#<IRB::SLex::Node:0x00000002ea5928 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
"\u001A"=>#<IRB::SLex::Node:0x00000002ea5540 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea6120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:343>>, 
" "=>#<IRB::SLex::Node:0x00000002ea4e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\t"=>#<IRB::SLex::Node:0x00000002ea4b68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\f"=>#<IRB::SLex::Node:0x00000002ea4668 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\r"=>#<IRB::SLex:
 :Node:0x00000002ea4078 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"\v"=>#<IRB::SLex::Node:0x00000002e9feb0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002ea51d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:347>>, 
"#"=>#<IRB::SLex::Node:0x00000002e9fbe0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9fdc0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:354>>, 
"="=>#<IRB::SLex::Node:0x00000002e9f618 
@Tree={"b"=>#<IRB::SLex::Node:0x00000002e9f5a0 
@Tree={"e"=>#<IRB::SLex::Node:0x00000002e9f550 
@Tree={"g"=>#<IRB::SLex::Node:0x00000002e9f460 
@Tree={"i"=>#<IRB::SLex::Node:0x00000002e9f410 
@Tree={"n"=>#<IRB::SLex::Node:0x00000002e9f3c0 @Tree={}, 
@preproc=#<Proc:0x00000002e9fb40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>, 
@postproc=#<Proc:0x00000002e9fb18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:359>>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>}, 
@preproc=nil, @postproc=nil>}, @preproc=nil, @postproc=nil>, "="=>#<IRB:
 :SLex::Node:0x00000002e9d9a8 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e9d660 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e9d1b0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"\n"=>#<IRB::SLex::Node:0x00000002e9ecb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9efd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:371>>, 
"*"=>#<IRB::SLex::Node:0x00000002e9e4c0 
@Tree={"*"=>#<IRB::SLex::Node:0x00000002e9e010 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8d4e0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"="=
 >#<IRB::SLex::Node:0x00000002e8d850 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e9cc38 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e9cb98 
@Tree={">"=>#<IRB::SLex::Node:0x00000002e9cb20 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"<"=>#<IRB::SLex::Node:0x00000002e94790 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86f28 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e949e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:406>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e96158 @Tree={
 "="=>#<IRB::SLex::Node:0x00000002e95820 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
">"=>#<IRB::SLex::Node:0x00000002e955a0 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e869d8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"!"=>#<IRB::SLex::Node:0x00000002e95230 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e94ec0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"~"=>#<IRB::SLex::Node:0x00000002e94b00 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e9e858@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:395>>, 
"'"=>#<IRB::SLex::Node:0x00000002e94268 @
 Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"\""=>#<IRB::SLex::Node:0x00000002e8ed18 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e94650@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:428>>, 
"`"=>#<IRB::SLex::Node:0x00000002e8fc68 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8ff10@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:433>>, 
"?"=>#<IRB::SLex::Node:0x00000002e8f8d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8fb00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:443>>, 
"&"=>#<IRB::SLex::Node:0x00000002e8f560 
@Tree={"&"=>#<IRB::SLex::Node:0x00000002e8f178 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e85b50 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8d030 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ru
 by-lex.rb:471>>}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"|"=>#<IRB::SLex::Node:0x00000002e8ee30 
@Tree={"|"=>#<IRB::SLex::Node:0x00000002e8e750 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e86460 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"="=>#<IRB::SLex::Node:0x00000002e8c1a8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e8f6c8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:464>>, 
"+"=>#<IRB::SLex::Node:0x00000002e8de90 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8de40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e852b8 @Tree={}, 
@preproc=#<Proc:0x00000002e85768@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb
 :478>, 
@postproc=#<Proc:0x00000002e85740@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:478>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"-"=>#<IRB::SLex::Node:0x00000002e8db98 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e8db48 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>, 
"@"=>#<IRB::SLex::Node:0x00000002e84ed0 @Tree={}, 
@preproc=#<Proc:0x00000002e851a0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>, 
@postproc=#<Proc:0x00000002e85150@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:484>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e843b8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:490>>, 
"^"=>#<IRB::SLex::Node:0x00000002e87298 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e876d0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e8e110@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:471>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7e120@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:578>>, 
"."=>#<IRB::SLex::Node:0x00000002e7
 fd68 @Tree={"."=>#<IRB::SLex::Node:0x00000002e7f930 
@Tree={"."=>#<IRB::SLex::Node:0x00000002e7f548 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7fc00@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:521>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7ff20@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:508>>, 
"]"=>#<IRB::SLex::Node:0x00000002e7f0e8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
"}"=>#<IRB::SLex::Node:0x00000002e7ee40 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
")"=>#<IRB::SLex::Node:0x00000002e7eb98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7f368@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:531>>, 
":"=>#<IRB::SLex::Node:0x00000002e7e8a0 
@Tree={":"=>#<IRB::SLex::Node:0x00000002e7e558 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e7d8@c:/usr/lib/ruby/2.0.0/irb
 /ruby-lex.rb:550>>}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7ead0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:539>>, 
"/"=>#<IRB::SLex::Node:0x00000002e7e238 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7e490@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:562>>, 
","=>#<IRB::SLex::Node:0x00000002e7dbd0 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7ddd8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:589>>, 
";"=>#<IRB::SLex::Node:0x00000002e7d810 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7da40@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:595>>, 
"~"=>#<IRB::SLex::Node:0x00000002e7d540 
@Tree={"@"=>#<IRB::SLex::Node:0x00000002e7d0e0 @Tree={}, 
@preproc=#<Proc:0x00000002e7d400@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>, 
@postproc=#<Proc:0x00000002e7d388@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:612>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7d770@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:606>>, 
"("=>#<IRB::SLex::Node:0x00000002e7cd98 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7cfc8@c
 :/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:618>>, 
"["=>#<IRB::SLex::Node:0x00000002e7ca28 
@Tree={"]"=>#<IRB::SLex::Node:0x00000002e7c9d8 
@Tree={"="=>#<IRB::SLex::Node:0x00000002e7c5a0 @Tree={}, 
@preproc=#<Proc:0x00000002e7c898@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>, 
@postproc=#<Proc:0x00000002e7c870@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:638>>}, 
@preproc=#<Proc:0x00000002e7cc58@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>, 
@postproc=#<Proc:0x00000002e7cc30@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:632>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e7c4d8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:644>>, 
"{"=>#<IRB::SLex::Node:0x00000002e7c0c8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e7c2d0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:663>>, 
"\\"=>#<IRB::SLex::Node:0x00000002e77e38 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77fa0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:676>>, 
"%"=>#<IRB::SLex::Node:0x00000002e77bb8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77d70@c:/usr/li
 b/ruby/2.0.0/irb/ruby-lex.rb:688>>, 
"$"=>#<IRB::SLex::Node:0x00000002e77988 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e77b18@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:703>>, 
"@"=>#<IRB::SLex::Node:0x00000002e776b8 @Tree={}, @preproc=nil, 
@postproc=#<Proc:0x00000002e778e8@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:708>>}, 
@preproc=nil, 
@postproc=#<Proc:0x00000002e775f0@c:/usr/lib/ruby/2.0.0/irb/ruby-lex.rb:728>>>, 
@io=#<IRB::StdioInputMethod:0x00000003009828 @file_name="(line)", 
@line_no=1, @line=[nil, "exit\n"], @stdin=#<IO:fd 0>, @stdout=#<IO:fd 
1>, @prompt="irb(main):001:0> ">, 
@input=#<Proc:0x0000000291b520@c:/usr/lib/ruby/2.0.0/irb.rb:457>, 
@seek=4, @line_no=1, @exp_line_no=1, @base_char_no=0, @char_no=4, 
@rests=["\n"], @readed=["e", "x", "i", "t"], @here_readed=[], @indent=0, 
@indent_stack=[], @lex_state=:EXPR_ARG, @space_seen=false, 
@here_header=false, @continue=false, @line="", @skip_space=false, 
@readed_auto_clean_up=false, @exception_on_syntax_error=false, @prompt=#
 <Proc:0x0000000291b548@c:/usr/lib/ruby/2.0.0/irb.rb:430>, @ltype=nil, 
@quoted=nil, @prev_seek=0, @prev_line_no=1, @prev_char_no=0>
\n

I think the patch 
https://bugs.ruby-lang.org/attachments/2611/irb_de... should 
be applied for init.rb.
----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301#change-35082

Author: sho-h (Sho Hashimoto)
Status: Closed
Priority: Normal
Assignee: keiju (Keiju Ishitsuka)
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Posted by keiju (Keiju Ishitsuka) (Guest)
on 2012-12-26 05:03
(Received via mailing list)
Issue #6301 has been updated by keiju (Keiju Ishitsuka).


phasis68 (Heesob Park) wrote:
> After the changeset r38611, the output of irb is too verbose by default.

Sorry, I have updated again.



----------------------------------------
Bug #6301: irb 起動後に conf.debug_level を変更するとエラーになる
https://bugs.ruby-lang.org/issues/6301#change-35085

Author: sho-h (Sho Hashimoto)
Status: Closed
Priority: Normal
Assignee: keiju (Keiju Ishitsuka)
Category: lib
Target version:
ruby -v: ruby 1.9.3p125 (2012-02-16 revision 34643) [x86_64-linux]


$ irb --irb_debug <数字> などでは問題ありませんが、irb の起動後に conf.debug_level 
を設定するとエラーになるようです。(1.9.3-p125 で確認しましたが、trunk でも同様のようです)

> conf.debug_level = "1"
NoMethodError: undefined method `debug_level=' for IRB::SLex:Class
  from 
/home/sho-h/.rvm/rubies/ruby-1.9.3-p125/lib/ruby/1.9.1/irb/context.rb:245:in 
`debug_level='

IRB::SLex.debug_level を代入するのを止めるか、debug_level を追加するのがよいのではないかと思いました。

--- lib/irb/context.rb  (revision 35336)
+++ lib/irb/context.rb  (working copy)
@@ -242,7 +242,6 @@
     def debug_level=(value)
       @debug_level = value
       RubyLex.debug_level = value
-      SLex.debug_level = value
     end

     def debug?
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.