
#12927: Colorized error messages result in hard-to-read .dump-* files -------------------------------------+------------------------------------- Reporter: RyanGlScott | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.1 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: Other Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: #8809 Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- To see this, compile this file: {{{#!hs module Main where x :: String -> String x s = print (reverse s + 1) }}} with `ghc-stage2 -ddump-tc-trace -ddump-to-file`. If you look at the resulting `.dump-tc-trace` file with a text editor like `vim`, you'll see at the bottom: {{{ ... Tc7a checkMain fail Main main Adding error: ^[[;1mBug.hs:1:1: ^[[;1m^[[31merror:^[[;1m The IO action ‘main’ is not defined in module ‘Main’^[[0m }}} The error message is now much harder to discern that before the introduction of colorized error messages. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12927 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler