X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=Prelude.hs;h=8ede773a3674646398dd2744bbb08a30acc749aa;hb=566d4ea2e4434bf0bedfaa518c31bca42959855d;hp=1006bdcf1149063d84e0b4d5f5f24a5fa42a3204;hpb=8afc9fecd586d3c4f7ef9c69fb1686a79e5f441d;p=ghc-base.git diff --git a/Prelude.hs b/Prelude.hs index 1006bdc..8ede773 100644 --- a/Prelude.hs +++ b/Prelude.hs @@ -1,4 +1,4 @@ -{-# OPTIONS_GHC -XNoImplicitPrelude #-} +{-# OPTIONS_GHC -XNoImplicitPrelude -XBangPatterns #-} ----------------------------------------------------------------------------- -- | -- Module : Prelude @@ -172,12 +172,16 @@ import Hugs.Prelude #ifndef __HUGS__ infixr 0 $! +#endif -- ----------------------------------------------------------------------------- -- Miscellaneous functions -- | Strict (call-by-value) application, defined in terms of 'seq'. ($!) :: (a -> b) -> a -> b +#ifdef __GLASGOW_HASKELL__ +f $! x = let !vx = x in f vx -- see #2273 +#elif !defined(__HUGS__) f $! x = x `seq` f x #endif