units: Use 100 column width in rustdoc comments

We typically use 100 column width for comments, do so but only if it
does not make the layout worse.
This commit is contained in:
Tobin C. Harding 2025-04-08 13:44:37 +10:00
parent 53c6ae4d40
commit da69e636a9
No known key found for this signature in database
GPG Key ID: 40BF9E4C269D6607
2 changed files with 8 additions and 10 deletions

View File

@ -141,10 +141,9 @@ impl FeeRate {
/// Checked weight multiplication.
///
/// Computes the absolute fee amount for a given [`Weight`] at this fee rate.
/// When the resulting fee is a non-integer amount, the amount is rounded up,
/// ensuring that the transaction fee is enough instead of falling short if
/// rounded down.
/// Computes the absolute fee amount for a given [`Weight`] at this fee rate. When the resulting
/// fee is a non-integer amount, the amount is rounded up, ensuring that the transaction fee is
/// enough instead of falling short if rounded down.
///
/// Returns [`None`] if overflow occurred.
#[must_use]
@ -198,10 +197,9 @@ crate::internal_macros::impl_op_for_references! {
impl Weight {
/// Checked fee rate multiplication.
///
/// Computes the absolute fee amount for a given [`FeeRate`] at this weight.
/// When the resulting fee is a non-integer amount, the amount is rounded up,
/// ensuring that the transaction fee is enough instead of falling short if
/// rounded down.
/// Computes the absolute fee amount for a given [`FeeRate`] at this weight. When the resulting
/// fee is a non-integer amount, the amount is rounded up, ensuring that the transaction fee is
/// enough instead of falling short if rounded down.
///
/// Returns [`None`] if overflow occurred.
#[must_use]

View File

@ -12,8 +12,8 @@ use arbitrary::{Arbitrary, Unstructured};
/// Represents fee rate.
///
/// This is an integer newtype representing fee rate in `sat/kwu`. It provides protection against mixing
/// up the types as well as basic formatting features.
/// This is an integer newtype representing fee rate in `sat/kwu`. It provides protection against
/// mixing up the types as well as basic formatting features.
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct FeeRate(u64);