packages feed

secp256k1-haskell 1.5.1 → 1.6.0

raw patch · 4 files changed

+9/−9 lines, 4 files

Files

CHANGELOG.md view
@@ -4,6 +4,13 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [1.6.0] - 2026-10-31++### Removed++- No longer does this module expose the destroyContext function.+  Context is now only destroyed safely by the garbage collector.+ ## [1.5.1] - 2026-10-31  ### Fixed
secp256k1-haskell.cabal view
@@ -5,7 +5,7 @@ -- see: https://github.com/sol/hpack  name:           secp256k1-haskell-version:        1.5.1+version:        1.6.0 synopsis:       Bindings for secp256k1 description:    Sign and verify signatures using the secp256k1 library. category:       Crypto
src/Crypto/Secp256k1.hs view
@@ -3,10 +3,6 @@   ( -- * Context     Ctx (..),     withContext,-    randomizeContext,-    createContext,-    cloneContext,-    destroyContext,      -- * Messages     Msg (..),
src/Crypto/Secp256k1/Internal/Context.hs view
@@ -23,7 +23,7 @@ import GHC.Conc (writeTVar) import System.IO.Unsafe (unsafePerformIO) -newtype Ctx = Ctx {get :: ForeignPtr LCtx}+data Ctx = Ctx (ForeignPtr LCtx)  randomizeContext :: Ctx -> IO () randomizeContext (Ctx fctx) = withForeignPtr fctx $ \ctx -> do@@ -43,9 +43,6 @@   withForeignPtr fctx $ \ctx -> mask_ $ do     ctx' <- contextClone ctx     Ctx <$> newForeignPtr contextDestroyFunPtr ctx'--destroyContext :: Ctx -> IO ()-destroyContext (Ctx fctx)= finalizeForeignPtr fctx  withContext :: (Ctx -> IO a) -> IO a withContext = (createContext >>=)