on master help sign in
Add putStrLn to Control.ST for ConsoleIO
698705eEdwin Brady
libs/contrib/Control/ST.idr+4
@@ -539,6 +539,10 @@ interface ConsoleIO (m : Type -> Type) where
539 putStr : String -> STrans m () xs (const xs)
539 putStr : String -> STrans m () xs (const xs)
540 getStr : STrans m String xs (const xs)
540 getStr : STrans m String xs (const xs)
541
541
542+export
543+putStrLn : ConsoleIO m => String -> STrans m () xs (const xs)
544+putStrLn str = putStr (str ++ "\n")
545+
542export
546export
543ConsoleIO IO where
547ConsoleIO IO where
544 putStr str = lift (Interactive.putStr str)
548 putStr str = lift (Interactive.putStr str)