Merge rust-bitcoin/rust-bitcoin#1404: Check for rustdocs build warnings in CI

108a1f73ca Fail CI if docs build throws warnings (Tobin C. Harding)
b014f0fdcb Fix rustdocs build warnings (Tobin C. Harding)

Pull request description:

  Currently we do not fail the CI script if the docs build throws warnings, since we are a group of super anal, easily triggered, code cleanliness obsessed devs this causes a mild rash to develop on the lower back [0]. We can easily fix this by checking for build warnings in CI.

  [0] - Amusingly my rash has been playing up since Friday but I thought I'd fixed the warnings in an open PR someplace so I was ignoring it, seeing Kixunil's [issue](https://github.com/rust-bitcoin/rust-bitcoin/issues/1403) this morning prompted me to fix it :)

  Fix #1403

ACKs for top commit:
  Kixunil:
    ACK 108a1f73ca
  apoelstra:
    ACK 108a1f73ca

Tree-SHA512: 0f86c318b2ec8bf7aa6a0d0f355f8fe8e3eb8ad5eb74d95f8dab882d6729c386c3e0ef4cc2378645e15460ff2b9b47d66e3603958f8b188f5e2b07272739d755
This commit is contained in:
Andrew Poelstra 2022-11-21 15:30:10 +00:00
commit 1e4b5e34ae
No known key found for this signature in database
GPG Key ID: C588D63CE41B97C1
4 changed files with 4 additions and 4 deletions

View File

@ -81,7 +81,7 @@ cargo run --example taproot-psbt --features=bitcoinconsensus
# Build the docs if told to (this only works with the nightly toolchain)
if [ "$DO_DOCS" = true ]; then
RUSTDOCFLAGS="--cfg docsrs" cargo +nightly rustdoc --features="$FEATURES" -- -D rustdoc::broken-intra-doc-links
RUSTDOCFLAGS="--cfg docsrs" cargo +nightly rustdoc --all-features -- -D rustdoc::broken-intra-doc-links -D warnings || exit 1
fi
# Fuzz if told to

View File

@ -1348,7 +1348,7 @@ pub mod serde {
}
pub mod opt {
//! Serialize and deserialize [Option<Amount>] as JSON numbers denominated in BTC.
//! Serialize and deserialize `Option<Amount>` as JSON numbers denominated in BTC.
//! Use with `#[serde(default, with = "amount::serde::as_btc::opt")]`.
use core::fmt;

View File

@ -29,7 +29,7 @@ use crate::util::taproot::TAPROOT_ANNEX_PREFIX;
///
#[derive(Clone, Default, PartialEq, Eq, PartialOrd, Ord, Debug, Hash)]
pub struct Witness {
/// Contains the witness Vec<Vec<u8>> serialization without the initial varint indicating the
/// Contains the witness `Vec<Vec<u8>>` serialization without the initial varint indicating the
/// number of elements (which is stored in `witness_elements`)
content: Vec<u8>,

View File

@ -113,7 +113,7 @@ pub struct Input {
pub hash256_preimages: BTreeMap<sha256d::Hash, Vec<u8>>,
/// Serialized schnorr signature with sighash type for key spend.
pub tap_key_sig: Option<SchnorrSig>,
/// Map of <xonlypubkey>|<leafhash> with signature.
/// Map of `<xonlypubkey>|<leafhash>` with signature.
#[cfg_attr(feature = "serde", serde(with = "crate::serde_utils::btreemap_as_seq"))]
pub tap_script_sigs: BTreeMap<(XOnlyPublicKey, TapLeafHash), SchnorrSig>,
/// Map of Control blocks to Script version pair.