X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;ds=inline;f=System%2FMem%2FStableName.hs;h=a2f939797bdaaaab794687adb858895695b5335e;hb=2b2397221c29a275630c62d4982caedc2c7cd987;hp=d582dae7d63af5aa505337813968dbb984f6bfcb;hpb=9812e0a321ec0ed8f9e53eb2febfb14c79564200;p=ghc-base.git diff --git a/System/Mem/StableName.hs b/System/Mem/StableName.hs index d582dae..a2f9397 100644 --- a/System/Mem/StableName.hs +++ b/System/Mem/StableName.hs @@ -31,7 +31,7 @@ module System.Mem.StableName ( import Prelude -import Data.Dynamic +import Data.Typeable #ifdef __HUGS__ import Hugs.Stable @@ -55,12 +55,14 @@ import GHC.Base ( Int(..), StableName#, makeStableName# the same object. The reverse is not necessarily true: if two stable names are not - equal, then the objects they name may still be equal. + equal, then the objects they name may still be equal. Note in particular + that `mkStableName` may return a different `StableName` after an + object is evaluated. - Stable Names are similar to Stable Pointers ('Foreign.StablePtr'), + Stable Names are similar to Stable Pointers ("Foreign.StablePtr"), but differ in the following ways: - * There is no @freeStableName@ operation, unlike 'Foreign.StablePtr's. + * There is no @freeStableName@ operation, unlike "Foreign.StablePtr"s. Stable names are reclaimed by the runtime system when they are no longer needed. @@ -110,5 +112,5 @@ instance Eq (StableName a) where #endif /* __GLASGOW_HASKELL__ */ -#include "Dynamic.h" +#include "Typeable.h" INSTANCE_TYPEABLE1(StableName,stableNameTc,"StableName")