about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--repl.lua7
1 files changed, 6 insertions, 1 deletions
diff --git a/repl.lua b/repl.lua index 016df17..c2233c4 100644 --- a/repl.lua +++ b/repl.lua
@@ -11,6 +11,8 @@ local function schemeprint (x)
11 print("#t") 11 print("#t")
12 elseif x == false then 12 elseif x == false then
13 print("#f") 13 print("#f")
14 elseif x == nil then
15 print("#n")
14 else 16 else
15 print(x) 17 print(x)
16 end 18 end
@@ -29,7 +31,10 @@ function m.repl (prompt, infile, out)
29 -- filename, nil (in which case it will be stdout), or false (which 31 -- filename, nil (in which case it will be stdout), or false (which
30 -- suppresses output) 32 -- suppresses output)
31 local inport = read.inport(infile) 33 local inport = read.inport(infile)
32 if out ~= false then io.output(out) end 34 if out ~= false then
35 io.output(out)
36 io.write(lam)
37 end
33 io.output():setvbuf("line") 38 io.output():setvbuf("line")
34 if prompt then 39 if prompt then
35 stderr = io.open("/dev/stderr", "w") -- Linux-only ! 40 stderr = io.open("/dev/stderr", "w") -- Linux-only !