mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-22 04:30:19 +02:00
* Added `call-with-readline-completion-function'.
This commit is contained in:
parent
8c84b81eca
commit
ee03460326
2 changed files with 14 additions and 0 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
2001-08-02 Neil Jerram <neil@ossau.uklinux.net>
|
||||||
|
|
||||||
|
* readline.scm (call-with-readline-completion-function): New.
|
||||||
|
|
||||||
2001-07-18 Martin Grabmueller <mgrabmue@cs.tu-berlin.de>
|
2001-07-18 Martin Grabmueller <mgrabmue@cs.tu-berlin.de>
|
||||||
|
|
||||||
* Makefile.am, readline.scm: Updated copyright notice.
|
* Makefile.am, readline.scm: Updated copyright notice.
|
||||||
|
|
|
@ -187,6 +187,16 @@
|
||||||
(set! *readline-completion-function* apropos-completion-function)
|
(set! *readline-completion-function* apropos-completion-function)
|
||||||
))
|
))
|
||||||
|
|
||||||
|
(define-public (call-with-readline-completion-function completer thunk)
|
||||||
|
"With @var{completer} as readline completion function, call @var{thunk}."
|
||||||
|
(let ((old-completer *readline-completion-function*))
|
||||||
|
(dynamic-wind
|
||||||
|
(lambda ()
|
||||||
|
(set! *readline-completion-function* completer))
|
||||||
|
thunk
|
||||||
|
(lambda ()
|
||||||
|
(set! *readline-completion-function* old-completer)))))
|
||||||
|
|
||||||
(define-public (activate-readline)
|
(define-public (activate-readline)
|
||||||
(if (and (isatty? (current-input-port))
|
(if (and (isatty? (current-input-port))
|
||||||
(not (and (module-defined? the-root-module 'use-emacs-interface)
|
(not (and (module-defined? the-root-module 'use-emacs-interface)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue