ghc-heap-view 0.6.2 → 0.6.3
raw patch · 3 files changed
+11/−11 lines, 3 filesdep ~basedep ~bytestringnew-uploaderPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependency ranges changed: base, bytestring
API changes (from Hackage documentation)
- GHC.HeapView: instance Data.Foldable.Foldable GHC.Exts.Heap.Closures.GenClosure
- GHC.HeapView: instance Data.Traversable.Traversable GHC.Exts.Heap.Closures.GenClosure
- GHC.HeapView: instance GHC.Base.Functor GHC.Exts.Heap.Closures.GenClosure
+ GHC.HeapView: SmallMutArrClosure :: !StgInfoTable -> !Word -> ![b] -> GenClosure b
+ GHC.HeapView: WeakClosure :: !StgInfoTable -> !b -> !b -> !b -> !b -> !b -> GenClosure b
+ GHC.HeapView: [cfinalizers] :: GenClosure b -> !b
+ GHC.HeapView: [finalizer] :: GenClosure b -> !b
+ GHC.HeapView: [key] :: GenClosure b -> !b
- GHC.HeapView: allClosures :: () => GenClosure b -> [b]
+ GHC.HeapView: allClosures :: GenClosure b -> [b]
- GHC.HeapView: asBox :: () => a -> Box
+ GHC.HeapView: asBox :: a -> Box
Files
- Test.hs +4/−4
- ghc-heap-view.cabal +5/−5
- src/GHC/Disassembler.hs +2/−2
Test.hs view
@@ -32,22 +32,22 @@ let !(I# m) = length args + 42 let !(I# m') = length args + 23- let f = \ y n -> take (I# m + I# y) n ++ args+ let f = \ y n -> take (I# m + I# y + 1) n ++ args performGC getClosureData f >>= \ cl -> do assertClosureType FUN_1_1 (info cl) unless (dataArgs cl == [42]) $ do- fail "Wrong data arg"+ fail $ "Type FUN_1_1: Wrong data arg '" <> show (dataArgs cl) <> "'" let t = f m' list2 getClosureData t >>= \ cl -> do assertClosureType THUNK (info cl) unless (dataArgs cl == [23]) $ do- fail "Wrong data arg"+ fail $ "Type THUNK Wrong data arg '" <> show (dataArgs cl) <> "'" eq <- areBoxesEqual (ptrArgs cl !! 1) (asBox f)- unless eq $ fail "t doesnt reference f"+ unless eq $ fail $ "Thunk doesnt reference function:\n\tthunk pointer = '" <> show (ptrArgs cl !! 1) <> "'\n\tfunction box = '" <> show (asBox f) <> "'\n" let z = id (:) () z z `seq` pure ()
ghc-heap-view.cabal view
@@ -1,5 +1,5 @@ Name: ghc-heap-view-Version: 0.6.2+Version: 0.6.3 Synopsis: Extract the heap representation of Haskell values and thunks Description: This library provides functions to introspect the Haskell heap, for example@@ -41,7 +41,7 @@ . The work on this package has been supported by the Deutsche Telekom Stiftung (<http://telekom-stiftung.de>).-tested-with: GHC == 8.6.1, GHC == 8.6.2, GHC == 8.6.3, GHC == 8.6.4, GHC == 8.6.5, GHC == 8.8.1, GHC == 8.10.1+tested-with: GHC == 8.6.1, GHC == 8.6.2, GHC == 8.6.3, GHC == 8.6.4, GHC == 8.6.5, GHC == 8.8.1, GHC == 8.10.1, GHC == 9.0.1, GHC == 9.2.1 License: BSD3 License-file: LICENSE Author: Joachim Breitner, Dennis Felsing@@ -61,7 +61,7 @@ custom-setup setup-depends: base setup-depends: filepath- setup-depends: Cabal >= 1.24 && < 3.3+ setup-depends: Cabal >= 1.24 && < 3.7 Library Default-Language: Haskell2010@@ -71,12 +71,12 @@ GHC.Disassembler GHC.HeapView.Debug Build-depends:- base >= 4.12 && < 4.15,+ base >= 4.12 && < 4.17, ghc-heap, containers, transformers, template-haskell,- bytestring >= 0.10,+ bytestring >= 0.10.2, binary Hs-source-dirs: src/ Ghc-options: -Wall
src/GHC/Disassembler.hs view
@@ -7,8 +7,8 @@ import qualified Data.ByteString.Lazy as BS import Data.ByteString.Lazy (ByteString)-import Data.ByteString.Lazy.Builder-import Data.ByteString.Lazy.Builder.Extras+import Data.ByteString.Builder+import Data.ByteString.Builder.Extra import Data.Binary.Get import Data.Word import Data.Int