-
Notifications
You must be signed in to change notification settings - Fork 2
Build with haskell-bitcoin #3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
src/Crypto/Secp256k1.hs
Outdated
@@ -395,6 +479,17 @@ exportSignatureDer (Signature fptr) = unsafePerformIO $ do | |||
unsafePackByteString (outBuf, len) | |||
|
|||
|
|||
-- | Convert signature to a normalized lower-S form. 'Nothing' indicates that it | |||
-- was already normal. | |||
normalizeSignature :: Signature -> Maybe Signature |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like it would be more ergonomic to have the signature Signature -> (Bool, Signature)
where the bool signals whether the signature return parameter is the original or a modified signature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed it. I also thought it was a bit awkward when copying it over from secp256k1-haskell
.
Yeah I think we're trying to ditch cereal as a dependency throughout this stack so I'm definitely gonna bias against merging this directly but we should keep it around as a template that we can rebase onto master after haskoin#31. |
Changes to get haskell-bitcoin to use this library. I'm using these changes locally as I've needed some of the Schnorr bindings upstream. I don't expect this to get merged as I've added some questionable dependencies and instances to get them to build together with minimal changes. Happy to close this once #31 is complete.
Related: haskell-bitcoin changes