wrap io.read with tostring to avoid windows concat issue

This commit is contained in:
Joaquin Iglesias Turina 2022-04-12 18:46:28 +02:00
parent 67ca04f967
commit 4ebd5685f8

View file

@ -4,7 +4,7 @@
;; can be used in a non-blocking way from another thread. ;; can be used in a non-blocking way from another thread.
(fn prompt [cont?] (fn prompt [cont?]
(io.write (if cont? ".." ">> ")) (io.flush) (.. (io.read) "\n")) (io.write (if cont? ".." ">> ")) (io.flush) (.. (tostring (io.read)) "\n"))
;; This module is loaded twice: initially in the main thread where ... is nil, ;; This module is loaded twice: initially in the main thread where ... is nil,
;; and then again in a separate thread where ... contains the channel used to ;; and then again in a separate thread where ... contains the channel used to