X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Futils%2FPanic.lhs;h=95878c4f52e598b6146553f78ec372c2c222988d;hb=8f47436d4941e7871569e47bf8c2f5a6180bdbd5;hp=ffc3c37247af71c079199a7c549d548b830d10f7;hpb=9f589efb688f22cb0637f9c1164dd9027b4378a3;p=ghc-hetmet.git diff --git a/compiler/utils/Panic.lhs b/compiler/utils/Panic.lhs index ffc3c37..95878c4 100644 --- a/compiler/utils/Panic.lhs +++ b/compiler/utils/Panic.lhs @@ -9,6 +9,13 @@ It's hard to put these functions anywhere else without causing some unnecessary loops in the module dependency graph. \begin{code} +{-# OPTIONS -w #-} +-- The above warning supression flag is a temporary kludge. +-- While working on this module you are encouraged to remove it and fix +-- any warnings in the module. See +-- http://hackage.haskell.org/trac/ghc/wiki/Commentary/CodingStyle#Warnings +-- for details + module Panic ( GhcException(..), showGhcException, ghcError, progName, @@ -128,7 +135,7 @@ Panics and asserts. \begin{code} panic, pgmError :: String -> a -panic x = Exception.throwDyn (Panic x) +panic x = trace ("Panic (" ++ x ++ ")") (Exception.throwDyn (Panic x)) pgmError x = Exception.throwDyn (ProgramError x) -- #-versions because panic can't return an unboxed int, and that's