Skip to content
This repository was archived by the owner on Feb 17, 2025. It is now read-only.

Commit 9978419

Browse files
crazymerlynyouknowone
authored andcommitted
Bump derive_more dependency to 1.0.0
1 parent 5130b05 commit 9978419

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,6 @@ rust-version = "1.74.0"
1212
malachite = "<=0.4.18"
1313
num-traits = { version = "0.2.11", default-features = false, features = ["i128"] }
1414
num-integer = { version = "0.1.45", default-features = false, features = ["i128"] }
15-
derive_more = "0.99.17"
15+
derive_more = { version = "1.0.0", features = ["display", "from", "into"] }
1616
paste = "1.0.12"
1717
num-bigint = { version = "0.4", default-features = false, optional = true }

src/bigint.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ use num_traits::{
1818
use paste::paste;
1919
use std::{
2020
cmp::Ordering,
21+
fmt::Debug,
2122
iter::{Product, Sum},
2223
ops::{
2324
Add, AddAssign, BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign, Div,
@@ -78,7 +79,7 @@ impl Neg for Sign {
7879
From,
7980
Into,
8081
)]
81-
#[display(fmt = "{}", "self.0")]
82+
#[display("{}", "self.0")]
8283
#[into(owned, ref, ref_mut)]
8384
pub struct BigInt(Integer);
8485

@@ -139,7 +140,7 @@ impl_sum_iter_type!(BigInt);
139140

140141
impl std::fmt::Debug for BigInt {
141142
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
142-
self.0.fmt(f)
143+
Debug::fmt(&self.0, f)
143144
}
144145
}
145146

src/biguint.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ use num_traits::{
1818
use paste::paste;
1919
use std::{
2020
cmp::Ordering::{Equal, Greater, Less},
21+
fmt::Debug,
2122
iter::{Product, Sum},
2223
ops::{
2324
Add, AddAssign, BitAnd, BitAndAssign, BitOr, BitOrAssign, BitXor, BitXorAssign, Div,
@@ -53,7 +54,7 @@ impl_primitive_convert!(BigUint, f64);
5354
From,
5455
Into,
5556
)]
56-
#[display(fmt = "{}", "self.0")]
57+
#[display("{}", "self.0")]
5758
#[into(owned, ref, ref_mut)]
5859
pub struct BigUint(pub(crate) Natural);
5960

@@ -112,7 +113,7 @@ impl_sum_iter_type!(BigUint);
112113

113114
impl std::fmt::Debug for BigUint {
114115
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
115-
self.0.fmt(f)
116+
Debug::fmt(&self.0, f)
116117
}
117118
}
118119

0 commit comments

Comments
 (0)