From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Jose A. Ortega Ruiz" Newsgroups: gmane.lisp.guile.devel Subject: Re: request for hack: readline fixes Date: Wed, 02 Jun 2010 15:48:09 +0200 Message-ID: <87aardim06.fsf@newton.homeunix.net> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: dough.gmane.org 1275487845 18918 80.91.229.12 (2 Jun 2010 14:10:45 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 2 Jun 2010 14:10:45 +0000 (UTC) To: guile-devel@gnu.org Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Wed Jun 02 16:10:40 2010 connect(): No such file or directory Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OJoeT-0003Ed-FX for guile-devel@m.gmane.org; Wed, 02 Jun 2010 16:10:37 +0200 Original-Received: from localhost ([127.0.0.1]:57280 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJoeS-0005rb-HV for guile-devel@m.gmane.org; Wed, 02 Jun 2010 10:10:36 -0400 Original-Received: from [140.186.70.92] (port=49174 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJocF-0003L6-Kb for guile-devel@gnu.org; Wed, 02 Jun 2010 10:08:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OJocA-0000VJ-Lg for guile-devel@gnu.org; Wed, 02 Jun 2010 10:08:19 -0400 Original-Received: from lo.gmane.org ([80.91.229.12]:35083) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OJocA-0000Ux-9t for guile-devel@gnu.org; Wed, 02 Jun 2010 10:08:14 -0400 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1OJoc6-0001jj-4Z for guile-devel@gnu.org; Wed, 02 Jun 2010 16:08:10 +0200 Original-Received: from 74.red-80-24-4.staticip.rima-tde.net ([80.24.4.74]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 02 Jun 2010 16:08:10 +0200 Original-Received: from jao by 74.red-80-24-4.staticip.rima-tde.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 02 Jun 2010 16:08:10 +0200 X-Injected-Via-Gmane: http://gmane.org/ connect(): No such file or directory Original-Lines: 59 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 74.red-80-24-4.staticip.rima-tde.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) X-Attribution: jao X-URL: Cancel-Lock: sha1:ZlAqcE48b7pgY8Xoway9P15oCCI= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.devel:10426 Archived-At: --=-=-= On Tue, Jun 01 2010, Andy Wingo wrote: > Hello list, > > It would be really great if someone could get to the bottom of our > readline support and fix a couple things. > > * Tab-completion: Works great for functions, not so much for arguments? > > If at the repl you type `(string-' and press tab, you get a list of > symbols bound in the current module that start with string-. Of > course it would be nice to restrict these to procedures, but hey. But > if you type `(string-ref fo' and press TAB, you get nothing, not even > if `foo' is bound. Bummer, no? It's been this way for at least 10 > years but I know that readline can do the right thing. Please fix? I think the attached 1-character patch fixes argument completion. Offering only callable symbols when completing on the first position is something i hadn't thought of for geiser: i'm probably implementing it there first and will try to backport the implementation to guile. > > * History: Expression-oriented, please! > > It would be great if going back in the history cycled through entire > expressions, not line-by-line. Again I know that readline can do > this. Please fix? :) I'll try to find the time for that too. In the meantime, just use geiser's REPL :) Cheers, jao -- A lot of people have my books on their bookshelves. That's the problem, they need to read them. -- Don Knuth --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=readline.patch diff --git a/guile-readline/readline.c b/guile-readline/readline.c index 2d3617d..ed524da 100644 --- a/guile-readline/readline.c +++ b/guile-readline/readline.c @@ -554,7 +554,7 @@ scm_init_readline () #else rl_completion_entry_function = (Function*) completion_function; #endif - rl_basic_word_break_characters = "\t\n\"'`;()"; + rl_basic_word_break_characters = " \t\n\"'`;()"; rl_readline_name = "Guile"; reentry_barrier_mutex = scm_make_mutex (); --=-=-=--