add fancy prompt before input
This commit is contained in:
parent
7bec9392c3
commit
061303ccc0
1 changed files with 2 additions and 1 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import Lox.Scanner
|
||||
import Lox.Parser
|
||||
import Lox.Interpreter
|
||||
import System.IO
|
||||
|
||||
run :: String -> IO ()
|
||||
run source = print result
|
||||
|
|
@ -9,4 +10,4 @@ run source = print result
|
|||
tokens = scanTokensFromSource source
|
||||
|
||||
main :: IO ()
|
||||
main = getLine >>= run
|
||||
main = putStr ">> " >> hFlush stdout >> getLine >>= run
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue