etscrivner / rbsecp256k1

Compiled Ruby wrapper around libsecp256k1 for secp256k1 ECDSA.
The Unlicense
19 stars 13 forks source link

Add exception hierarchy #46

Closed etscrivner closed 5 years ago

etscrivner commented 5 years ago

Closes #41 by adding the following exception hierarchy under the Secp256k1 module:

Error < StandardError
├── SerializationError
├── DeserializationError

These exceptions are then used to replace most occurrences of ArgumentError and RuntimeError. This will help packages using the library to isolate their exception handling code to just those exceptions raised by the library itself.