bump to 0.2.1

This commit is contained in:
EvilMuffinHa 2022-08-03 00:11:50 -04:00
parent f313051907
commit fca71af1df
2 changed files with 3 additions and 5 deletions

View File

@ -1,6 +1,6 @@
[package] [package]
name = "smallint" name = "smallint"
version = "0.2.0" version = "0.2.1"
edition = "2021" edition = "2021"
authors = ["artofrev"] authors = ["artofrev"]
description = "A library for optimized arbitrary precision integers." description = "A library for optimized arbitrary precision integers."

View File

@ -63,21 +63,20 @@ enum SmallUintType {
// TODO: add native operations for SmallInt and SmallUint // TODO: add native operations for SmallInt and SmallUint
#[cfg(feature="num-bigint")] #[cfg(feature = "num-bigint")]
impl core::fmt::Debug for SmallInt { impl core::fmt::Debug for SmallInt {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{}", BigInt::from(self)) write!(f, "{}", BigInt::from(self))
} }
} }
#[cfg(feature="num-bigint")] #[cfg(feature = "num-bigint")]
impl core::fmt::Debug for SmallUint { impl core::fmt::Debug for SmallUint {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(f, "{}", BigUint::from(self)) write!(f, "{}", BigUint::from(self))
} }
} }
impl Drop for SmallInt { impl Drop for SmallInt {
fn drop(&mut self) { fn drop(&mut self) {
if let Self(SmallIntType::Heap((r, s))) = self { if let Self(SmallIntType::Heap((r, s))) = self {
@ -363,5 +362,4 @@ mod conversion_tests {
(Sign::Plus, vec![5, 4, 8, 3, 2, 9, 3]) (Sign::Plus, vec![5, 4, 8, 3, 2, 9, 3])
); );
} }
} }