mirror of
https://github.com/kanaka/mal.git
synced 2024-11-11 00:52:44 +03:00
8511096262
- Refactor readline (not editline yet) into readline_mod. - Ignore comments properly
16 lines
207 B
Julia
16 lines
207 B
Julia
module readline_mod
|
|
|
|
export do_readline
|
|
|
|
function do_readline(prompt)
|
|
print(prompt)
|
|
flush(STDOUT)
|
|
line = readline(STDIN)
|
|
if line == ""
|
|
return nothing
|
|
end
|
|
chomp(line)
|
|
end
|
|
|
|
end
|