[macruby-changes] [4635] DietRB/trunk/lib/irb/ext/completion.rb

source_changes at macosforge.org source_changes at macosforge.org
Fri Oct 8 03:51:57 PDT 2010


Revision: 4635
          http://trac.macosforge.org/projects/ruby/changeset/4635
Author:   eloy.de.enige at gmail.com
Date:     2010-10-08 03:51:56 -0700 (Fri, 08 Oct 2010)
Log Message:
-----------
Fix my faulty way of using Readline, thanks Manfred!

From: Eloy Duran <eloy.de.enige at gmail.com>

Modified Paths:
--------------
    DietRB/trunk/lib/irb/ext/completion.rb

Modified: DietRB/trunk/lib/irb/ext/completion.rb
===================================================================
--- DietRB/trunk/lib/irb/ext/completion.rb	2010-10-08 10:51:47 UTC (rev 4634)
+++ DietRB/trunk/lib/irb/ext/completion.rb	2010-10-08 10:51:56 UTC (rev 4635)
@@ -75,8 +75,10 @@
     def process_filter(tree)
       # [:call, [:hash, nil], :".", [:@ident, x, …]]
       #                                       ^
+      filter = tree[3][1]
+      x = @source[0..-(filter.length + 2)]
       if list = process_any(tree[1])
-        list.grep(/^#{tree[3][1]}/)
+        list.grep(/^#{filter}/).map { |m| "#{x}.#{m}" }
       end
     end
     
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20101008/c37f83af/attachment.html>


More information about the macruby-changes mailing list