mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2025-02-01 15:26:47 +01:00
inferior: Adjust to protocol (0 1).
* guix/inferior.scm (port->inferior): For protocol (0 x ...), where x >= 1, send the (() repl-version ...) form.
This commit is contained in:
parent
f06a26f5b5
commit
ec0a866172
1 changed files with 9 additions and 0 deletions
|
@ -159,6 +159,15 @@ (define* (port->inferior pipe #:optional (close close-port))
|
|||
(letrec ((result (inferior 'pipe pipe close (cons 0 rest)
|
||||
(delay (%inferior-packages result))
|
||||
(delay (%inferior-package-table result)))))
|
||||
|
||||
;; For protocol (0 1) and later, send the protocol version we support.
|
||||
(match rest
|
||||
((n _ ...)
|
||||
(when (>= n 1)
|
||||
(send-inferior-request '(() repl-version 0 1) result)))
|
||||
(_
|
||||
#t))
|
||||
|
||||
(inferior-eval '(use-modules (guix)) result)
|
||||
(inferior-eval '(use-modules (gnu)) result)
|
||||
(inferior-eval '(use-modules (ice-9 match)) result)
|
||||
|
|
Loading…
Reference in a new issue