+{-# LANGUAGE CPP #-}
+
+#ifdef __GLASGOW_HASKELL__
+{-# LANGUAGE ForeignFunctionInterface #-}
+#endif
+
-----------------------------------------------------------------------------
-- |
-- Module : System.Mem
import Prelude
+#ifdef __HUGS__
+import Hugs.IOExts
+#endif
+
#ifdef __GLASGOW_HASKELL__
-- | Triggers an immediate garbage collection
-foreign import ccall {-safe-} "performGC" performGC :: IO ()
+foreign import ccall {-safe-} "performMajorGC" performGC :: IO ()
+#endif
+
+#ifdef __NHC__
+import NHC.IOExtras (performGC)
#endif