Merge pull request #127 from jeandudey/2018-08-12-c-hidden

Hidde `From<T>` implementations for error types in Rustdoc.
This commit is contained in:
Andrew Poelstra 2018-08-12 23:43:01 +00:00 committed by GitHub
commit c16ae47871
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View File

@ -195,6 +195,7 @@ impl error::Error for Error {
} }
#[cfg(feature="bitcoinconsensus")] #[cfg(feature="bitcoinconsensus")]
#[doc(hidden)]
impl convert::From<bitcoinconsensus::Error> for Error { impl convert::From<bitcoinconsensus::Error> for Error {
fn from(err: bitcoinconsensus::Error) -> Error { fn from(err: bitcoinconsensus::Error) -> Error {
match err { match err {

View File

@ -147,18 +147,21 @@ pub fn propagate_err<T>(s: String, res: Result<T, Error>) -> Result<T, Error> {
res.map_err(|err| Error::Detail(s, Box::new(err))) res.map_err(|err| Error::Detail(s, Box::new(err)))
} }
#[doc(hidden)]
impl From<base58::Error> for Error { impl From<base58::Error> for Error {
fn from(e: base58::Error) -> Error { fn from(e: base58::Error) -> Error {
Error::Base58(e) Error::Base58(e)
} }
} }
#[doc(hidden)]
impl From<bitcoin_bech32::Error> for Error { impl From<bitcoin_bech32::Error> for Error {
fn from(e: bitcoin_bech32::Error) -> Error { fn from(e: bitcoin_bech32::Error) -> Error {
Error::Bech32(e) Error::Bech32(e)
} }
} }
#[doc(hidden)]
impl From<secp256k1::Error> for Error { impl From<secp256k1::Error> for Error {
fn from(e: secp256k1::Error) -> Error { fn from(e: secp256k1::Error) -> Error {
Error::Secp256k1(e) Error::Secp256k1(e)