[Git][ghc/ghc][master] ghci: print external interpreter trace messages to stderr instead of stdout
Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC Commits: 9788c0ec by Cheng Shao at 2026-01-21T16:10:24-05:00 ghci: print external interpreter trace messages to stderr instead of stdout This patch makes ghci print external interpreter trace messages to stderr instead of stdout, which is a much saner choice for diagnostic information. Closes #26807. - - - - - 1 changed file: - libraries/ghci/GHCi/Server.hs Changes: ===================================== libraries/ghci/GHCi/Server.hs ===================================== @@ -32,11 +32,12 @@ import Data.Binary import Text.Printf import System.Environment (getProgName, getArgs) import System.Exit +import System.IO type MessageHook = Msg -> IO Msg trace :: String -> IO () -trace s = getProgName >>= \name -> printf "[%20s] %s\n" name s +trace s = getProgName >>= \name -> hPrintf stderr "[%20s] %s\n" name s serv :: Bool -> MessageHook -> Pipe -> (forall a .IO a -> IO a) -> IO () serv verbose hook pipe restore = loop View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/9788c0ecb7288cdcbe067fa90f54ec24... -- View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/9788c0ecb7288cdcbe067fa90f54ec24... You're receiving this email because of your account on gitlab.haskell.org.
participants (1)
-
Marge Bot (@marge-bot)