Skip to content

Commit c65eafc

Browse files
committed
Make I/O char-based on CLisp
This fixes the REPL on the version provided by Ubuntu bionic
1 parent 70d16b3 commit c65eafc

File tree

2 files changed

+4
-8
lines changed

2 files changed

+4
-8
lines changed

src/overwrite.lsp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -210,14 +210,14 @@
210210
(|shen-cl.read-eval| "(defmacro cl.exit-macro [cl.exit] -> [cl.exit 0])")
211211
(|shen-cl.read-eval| "(defmacro shen-cl.exit-macro [shen-cl.exit] -> [cl.exit 0])")))
212212

213-
#+(or ccl sbcl)
213+
#+(or ccl clisp sbcl)
214214
(defun |shen.read-char-code| (s)
215215
(let ((c (read-char s nil -1)))
216216
(if (eq c -1)
217217
-1
218218
(char-int c))))
219219

220-
#+(or ccl sbcl)
220+
#+(or ccl clisp sbcl)
221221
(defun |pr| (x s)
222222
(write-string x s)
223223
(when (or (eq s |*stoutput*|) (eq s |*stinput*|))

src/primitives.lsp

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -391,12 +391,8 @@
391391

392392
#+clisp
393393
(handler-bind ((warning #'muffle-warning))
394-
(with-open-stream (*standard-input* (ext:make-stream :input :element-type 'unsigned-byte))
395-
(with-open-stream (*standard-output* (ext:make-stream :output :element-type 'unsigned-byte))
396-
(setq |*stoutput*| *standard-output*)
397-
(setq |*stinput*| *standard-input*)
398-
(let ((args (cons (car (coerce (ext:argv) 'list)) ext:*args*)))
399-
(|shen-cl.toplevel-interpret-args| args)))))
394+
(let ((args (cons (car (coerce (ext:argv) 'list)) ext:*args*)))
395+
(|shen-cl.toplevel-interpret-args| args)))
400396

401397
#+ccl
402398
(handler-bind ((warning #'muffle-warning))

0 commit comments

Comments
 (0)