Merge rust-bitcoin/rust-bitcoin#1887: Remove doc(hidden) from error conversion functions
042dcaa4b7
Remove doc(hidden) from error conversion functions (Tobin C. Harding) Pull request description: Give people access to the error type conversion docs, its no harm and it may be useful when the compiler does not give enough information. Done based on discussion here: https://github.com/rust-bitcoin/rust-bitcoin/pull/1846#discussion_r1209583520 ACKs for top commit: Kixunil: ACK042dcaa4b7
apoelstra: ACK042dcaa4b7
Tree-SHA512: 9d975845ba84213b203062282b68f06f6790d03dbc88d66dce82e9bedff4696fc01da6216920de9e9e4130f6469b32ff9c168d0800d057ec0bae51702d4a139e
This commit is contained in:
commit
6a04ca12e0
|
@ -148,12 +148,10 @@ impl std::error::Error for Error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<base58::Error> for Error {
|
impl From<base58::Error> for Error {
|
||||||
fn from(e: base58::Error) -> Error { Error::Base58(e) }
|
fn from(e: base58::Error) -> Error { Error::Base58(e) }
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<bech32::Error> for Error {
|
impl From<bech32::Error> for Error {
|
||||||
fn from(e: bech32::Error) -> Error { Error::Bech32(e) }
|
fn from(e: bech32::Error) -> Error { Error::Bech32(e) }
|
||||||
}
|
}
|
||||||
|
|
|
@ -779,7 +779,6 @@ impl From<UintError> for Error {
|
||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(feature = "bitcoinconsensus")]
|
#[cfg(feature = "bitcoinconsensus")]
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<bitcoinconsensus::Error> for Error {
|
impl From<bitcoinconsensus::Error> for Error {
|
||||||
fn from(err: bitcoinconsensus::Error) -> Error { Error::BitcoinConsensus(err) }
|
fn from(err: bitcoinconsensus::Error) -> Error { Error::BitcoinConsensus(err) }
|
||||||
}
|
}
|
||||||
|
|
|
@ -93,7 +93,6 @@ impl std::error::Error for Error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<io::Error> for Error {
|
impl From<io::Error> for Error {
|
||||||
fn from(error: io::Error) -> Self { Error::Io(error) }
|
fn from(error: io::Error) -> Self { Error::Io(error) }
|
||||||
}
|
}
|
||||||
|
|
|
@ -65,17 +65,14 @@ impl std::error::Error for Error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<base58::Error> for Error {
|
impl From<base58::Error> for Error {
|
||||||
fn from(e: base58::Error) -> Error { Error::Base58(e) }
|
fn from(e: base58::Error) -> Error { Error::Base58(e) }
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<secp256k1::Error> for Error {
|
impl From<secp256k1::Error> for Error {
|
||||||
fn from(e: secp256k1::Error) -> Error { Error::Secp256k1(e) }
|
fn from(e: secp256k1::Error) -> Error { Error::Secp256k1(e) }
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<hex::Error> for Error {
|
impl From<hex::Error> for Error {
|
||||||
fn from(e: hex::Error) -> Self { Error::Hex(e) }
|
fn from(e: hex::Error) -> Self { Error::Hex(e) }
|
||||||
}
|
}
|
||||||
|
|
|
@ -203,7 +203,6 @@ impl std::error::Error for Error {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<hashes::FromSliceError> for Error {
|
impl From<hashes::FromSliceError> for Error {
|
||||||
fn from(e: hashes::FromSliceError) -> Error { Error::HashParse(e) }
|
fn from(e: hashes::FromSliceError) -> Error { Error::HashParse(e) }
|
||||||
}
|
}
|
||||||
|
|
|
@ -68,7 +68,6 @@ mod message_signing {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
#[doc(hidden)]
|
|
||||||
impl From<secp256k1::Error> for MessageSignatureError {
|
impl From<secp256k1::Error> for MessageSignatureError {
|
||||||
fn from(e: secp256k1::Error) -> MessageSignatureError {
|
fn from(e: secp256k1::Error) -> MessageSignatureError {
|
||||||
MessageSignatureError::InvalidEncoding(e)
|
MessageSignatureError::InvalidEncoding(e)
|
||||||
|
|
Loading…
Reference in New Issue