From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Matthew Henry Newsgroups: gmane.lisp.guile.bugs Subject: bug#37086: Guile Ice-9 Readline with-readline-completion-function Date: Mon, 19 Aug 2019 20:12:27 -0400 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="22341"; mail-complaints-to="usenet@blaine.gmane.org" To: 37086@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Tue Aug 20 03:08:17 2019 Return-path: Envelope-to: guile-bugs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hzsdE-0005h9-RM for guile-bugs@m.gmane.org; Tue, 20 Aug 2019 03:08:16 +0200 Original-Received: from localhost ([::1]:60606 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1hzsdD-0001dd-Bi for guile-bugs@m.gmane.org; Mon, 19 Aug 2019 21:08:15 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:58965) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1hzsd2-0001cI-53 for bug-guile@gnu.org; Mon, 19 Aug 2019 21:08:05 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hzsd0-0005d8-Fa for bug-guile@gnu.org; Mon, 19 Aug 2019 21:08:04 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:51839) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hzsd0-0005d3-Bv for bug-guile@gnu.org; Mon, 19 Aug 2019 21:08:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hzsd0-00029l-5Q for bug-guile@gnu.org; Mon, 19 Aug 2019 21:08:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: Resent-From: Matthew Henry Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Tue, 20 Aug 2019 01:08:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 37086 X-GNU-PR-Package: guile Original-Received: via spool by 37086-submit@debbugs.gnu.org id=B37086.15662632568251 (code B ref 37086); Tue, 20 Aug 2019 01:08:02 +0000 Original-Received: (at 37086) by debbugs.gnu.org; 20 Aug 2019 01:07:36 +0000 Original-Received: from localhost ([127.0.0.1]:60660 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hzsca-000290-G3 for submit@debbugs.gnu.org; Mon, 19 Aug 2019 21:07:36 -0400 Original-Received: from mail-wm1-f65.google.com ([209.85.128.65]:40224) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hzrlV-0000p0-KC for 37086@debbugs.gnu.org; Mon, 19 Aug 2019 20:12:46 -0400 Original-Received: by mail-wm1-f65.google.com with SMTP id v19so1015905wmj.5 for <37086@debbugs.gnu.org>; Mon, 19 Aug 2019 17:12:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=YlWLaApuWST3h9MRZshkTwucvg3eSSJvsO3GvxDoCQ0=; b=uURNApnCl6lp3UBj6UrhPedAyxQ9u+9f4CGkZvK9Mk2OdAKg0pp0DQLtk6Rni7AREt fHVm0IdPsRLNVlPU08iMTGy62/M419sUyZjs4GyJf/+6ZuNMW2upi4WRNFqXKseDdFcP 7CEDwAIafd4UznSbHOBSfd9Izs3wxyNo95u0UiCfoTI1BSJxhq0OC4mMIJ3tQ2U2DLfT +cgehiZW2sw1fas3JP/PT5hIf7SYqJte6j6QcX2fFci71gclChM4NZGT2FreYkia5aNH SYzB+8v5m/JsX/JKxRcw7vfbXbqeO8fkhK50P+zrc47/PsNUKj+z5VpifMXOoMjLpgDh 45Hw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=YlWLaApuWST3h9MRZshkTwucvg3eSSJvsO3GvxDoCQ0=; b=ev6jdHlGJp5yUR3vmcpAcb80qiOFV/A/vvv7AF8wEzt1JTS55VAK9DkexFbE4Tnxtz 12f8+q7JTEFr8gyIyLzH5cCzKRLF/3XXfYxbJ0pD1xQgc6j6S9Lv+uq67OA8SfN/GaR8 j+6p26YRHb4Ecq3SFT9Lm5CYulzUjEoOv2+QVxl+S9OS7fvL6MTzvwdj/jkdkPsja7Vp YXUrscz/7sU5+u9S4tps6N1EMMOKxJMqXYXoIy1RdBruMDNpK9RASTrE6iDyzLeIrFzu Tn662EbQ3Tr5k7KZ9OvpUKMJZPEU8w2JfIJH/LSaTWPyYJmEzKFLV+DlfrHWcKvDiAIZ VBEQ== X-Gm-Message-State: APjAAAUQcGAw7Fbh7I/Rpzpb9zoB1xOUir75/GbNDWA5XPM+qSg/bhG5 VaGZNtyAyXTnSeMh1p1KNMD7HXOdNuPpyyLZO2VKFP7B X-Google-Smtp-Source: APXvYqwf4JBZeEOFwY5d9j6PpXxINqA2XW6a2bbykY1YWL0NSHV6Oy9qRppXZ2aLaI+KhBZf33wTrlWxinogq4Uivmw= X-Received: by 2002:a1c:790b:: with SMTP id l11mr23331328wme.3.1566259959562; Mon, 19 Aug 2019 17:12:39 -0700 (PDT) X-Mailman-Approved-At: Mon, 19 Aug 2019 21:07:35 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.org gmane.lisp.guile.bugs:9419 Archived-At: I'm early in my Scheme journey, but here's a suggested fix: (define-syntax-rule (with-readline-completion-function completer expr ...) "With @var{completer} as readline completion function, call @var{expr ...}." (let ((old-completer *readline-completion-function*)) (dynamic-wind (lambda () (set! *readline-completion-function* completer)) (lambda () expr ...) (lambda () (set! *readline-completion-function* old-completer))))) (export with-readline-completion-function)