cmdline options: also set ext::*default-external-format* when --encoding is given

This commit is contained in:
Marius Gerbershagen 2021-03-06 20:25:19 +01:00
parent d528d5445b
commit 548309e165

View file

@ -82,9 +82,11 @@ appeared after a '--'.")
("--c-stack" 1 (ext:set-limit 'ext:c-stack (read-from-string 1)))
("--trap-fpe" 0 (si::trap-fpe t t))
("--no-trap-fpe" 0 (si::trap-fpe t nil))
("--encoding" 1 (dolist (i (list *standard-input* *standard-output*
*error-output* *trace-output*))
(setf (stream-external-format i) (read-from-string 1))))
("--encoding" 1 (let ((enc (read-from-string 1)))
(setf ext::*default-external-format* enc)
(dolist (i (list *standard-input* *standard-output*
*error-output* *trace-output*))
(setf (stream-external-format i) enc))))
("--input-encoding" 1
(setf (stream-external-format *standard-input*) (read-from-string 1)))
("--output-encoding" 1