X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Futils%2FFastString.lhs;h=cdabd626ca9d75a2a9b9668a5f628095ca67c13d;hb=a65481fce16930ff0cd343c9278d9b8961bee94f;hp=26f687c40fa99b19a8b43b4baaf724242b84665d;hpb=9c54ee0c9e25617b2a9ad4cdd9d3a6354e2edc0f;p=ghc-hetmet.git diff --git a/compiler/utils/FastString.lhs b/compiler/utils/FastString.lhs index 26f687c..cdabd62 100644 --- a/compiler/utils/FastString.lhs +++ b/compiler/utils/FastString.lhs @@ -161,6 +161,7 @@ data FastStringTable = {-# UNPACK #-} !Int (MutableArray# RealWorld [FastString]) +{-# NOINLINE string_table #-} string_table :: IORef FastStringTable string_table = unsafePerformIO $ do @@ -489,21 +490,7 @@ pokeCAString ptr str = in go str 0 -#if __GLASGOW_HASKELL__ < 600 - -mallocForeignPtrBytes :: Int -> IO (ForeignPtr a) -mallocForeignPtrBytes n = do - r <- mallocBytes n - newForeignPtr r (finalizerFree r) - -foreign import ccall unsafe "stdlib.h free" - finalizerFree :: Ptr a -> IO () - +#if __GLASGOW_HASKELL__ <= 602 peekCAStringLen = peekCStringLen - -#elif __GLASGOW_HASKELL__ <= 602 - -peekCAStringLen = peekCStringLen - #endif \end{code}