mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* lib/irb/completion.rb: treat rightly comletion for symbol on irb
[Bug #7632]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38656 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
cdabc58f8e
commit
b0767cf8c0
2 changed files with 7 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
Sat Dec 29 21:57:11 2012 Keiju Ishitsuka <keiju@ishitsuka.com>
|
||||
|
||||
* lib/irb/completion.rb: treat rightly comletion for symbol on irb
|
||||
[Bug #7632].
|
||||
|
||||
Sat Dec 29 21:51:30 2012 Shugo Maeda <shugo@ruby-lang.org>
|
||||
|
||||
* ext/curses/curses.c (window_cury, window_curx, window_maxy,
|
||||
|
|
|
@ -44,7 +44,7 @@ module IRB
|
|||
when /^((["'`]).*\2)\.([^.]*)$/
|
||||
# String
|
||||
receiver = $1
|
||||
message = $3
|
||||
message = Regexp.quote($3)
|
||||
|
||||
candidates = String.instance_methods.collect{|m| m.to_s}
|
||||
select_message(receiver, message, candidates)
|
||||
|
@ -79,7 +79,7 @@ module IRB
|
|||
if Symbol.respond_to?(:all_symbols)
|
||||
sym = $1
|
||||
candidates = Symbol.all_symbols.collect{|s| ":" + s.id2name}
|
||||
candidates.grep(/^#{sym}/)
|
||||
candidates.grep(/^#{Regexp.quote(sym)}/)
|
||||
else
|
||||
[]
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue