Improve difficulty rustdocs
Copy a sentence from the `pow::Target::difficulty` function onto the `block:Header::difficulty` function.
This commit is contained in:
parent
071208ccdd
commit
62af5b54f3
|
@ -69,6 +69,9 @@ impl Header {
|
||||||
pub fn target(&self) -> Target { self.bits.into() }
|
pub fn target(&self) -> Target { self.bits.into() }
|
||||||
|
|
||||||
/// Computes the popular "difficulty" measure for mining.
|
/// Computes the popular "difficulty" measure for mining.
|
||||||
|
///
|
||||||
|
/// Difficulty represents how difficult the current target makes it to find a block, relative to
|
||||||
|
/// how difficult it would be at the highest possible target (highest target == lowest difficulty).
|
||||||
pub fn difficulty(&self) -> u128 { self.target().difficulty() }
|
pub fn difficulty(&self) -> u128 { self.target().difficulty() }
|
||||||
|
|
||||||
/// Computes the popular "difficulty" measure for mining and returns a float value of f64.
|
/// Computes the popular "difficulty" measure for mining and returns a float value of f64.
|
||||||
|
|
Loading…
Reference in New Issue