summaryrefslogtreecommitdiff
path: root/lib/irb
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-08-16 12:32:35 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-08-16 12:32:35 +0000
commit5e4f23d600435fa5373cb40ff3c736c008caef52 (patch)
tree7cb18a2c775080e2c8bc89bfb534c58c77f25f56 /lib/irb
parent066b30245bea02bf217ea6b49fd2e906781e67c1 (diff)
* lib/date/format.rb: suppressed a warning.
* lib/irb/ruby-lex.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24555 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/irb')
-rw-r--r--lib/irb/ruby-lex.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/irb/ruby-lex.rb b/lib/irb/ruby-lex.rb
index c758f1dcf2..b49337c1c6 100644
--- a/lib/irb/ruby-lex.rb
+++ b/lib/irb/ruby-lex.rb
@@ -407,7 +407,7 @@ class RubyLex
if @lex_state != EXPR_END && @lex_state != EXPR_CLASS &&
(@lex_state != EXPR_ARG || @space_seen)
c = peek(0)
- if /\S/ =~ c && (/["'`]/ =~ c || /[\w_]/ =~ c || c == "-")
+ if /\S/ =~ c && (/["'`]/ =~ c || /\w/ =~ c || c == "-")
tk = identify_here_document
end
end
@@ -728,7 +728,7 @@ class RubyLex
printf "MATCH: start %s: %s\n", op, io.inspect if RubyLex.debug?
if peek(0) =~ /[0-9]/
t = identify_number
- elsif peek(0) =~ /[\w_]/
+ elsif peek(0) =~ /\w/
t = identify_identifier
end
printf "MATCH: end %s: %s\n", op, io.inspect if RubyLex.debug?