Skip to content

Commit

Permalink
Merge pull request #22 from GiacomoPope/repr_remove
Browse files Browse the repository at this point in the history
remove repr and use str
  • Loading branch information
GiacomoPope authored Aug 1, 2024
2 parents 89445e1 + d8a9875 commit 295f5c3
Showing 1 changed file with 3 additions and 15 deletions.
18 changes: 3 additions & 15 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,12 +103,8 @@ macro_rules! impl_sponge_shaker_classes {
Ok(())
}

fn __repr__(&self) -> String {
String::from(stringify!($sponge_name))
}

fn __str__(&self) -> String {
self.__repr__()
String::from(stringify!($sponge_name))
}
}
};
Expand Down Expand Up @@ -190,12 +186,8 @@ macro_rules! impl_sponge_shaker_classes {
}
}

fn __repr__(&self) -> String {
String::from(stringify!($shaker_name))
}

fn __str__(&self) -> String {
self.__repr__()
String::from($class_name)
}
}
};
Expand Down Expand Up @@ -252,12 +244,8 @@ macro_rules! impl_sponge_shaker_classes {
}
}

fn __repr__(&self) -> String {
String::from($class_name)
}

fn __str__(&self) -> String {
self.__repr__()
String::from($class_name)
}
}
};
Expand Down

0 comments on commit 295f5c3

Please sign in to comment.