Skip to content

Commit c7ad0e8

Browse files
committed
Improve Uint256::new docs
1 parent 5d0745a commit c7ad0e8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/std/src/math/uint256.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ impl Uint256 {
5151
pub const MAX: Uint256 = Uint256(U256::MAX);
5252

5353
/// Creates a Uint256(value) from a big endian representation. It's just an alias for
54-
/// `from_big_endian`.
54+
/// [`Uint256::from_be_bytes`].
55+
///
56+
/// This method is less flexible than `from` but can be called in a const context.
5557
pub const fn new(value: [u8; 32]) -> Self {
5658
Self::from_be_bytes(value)
5759
}

0 commit comments

Comments
 (0)