varunsrin / rusty_money

Money library for Rust
MIT License
85 stars 32 forks source link

feat: impl Copy for Money #82

Closed brokenthorn closed 1 year ago

brokenthorn commented 1 year ago

Addresses #60. Please kindly review.

brokenthorn commented 1 year ago

It just occurred to me that the next logical step after implementing Copy would be to check the codebase for manual .clone()'s that can be replaced by copies, at least for the aesthetic benefits (I believe the Clone impl already does the same byte copy as Copy, so there is probably no efficiency benefit to doing this refactoring).

Am I wrong?

brokenthorn commented 1 year ago

@varunsrin, not sure you saw this PR so tagging you just in case.

varunsrin commented 1 year ago

Looks great, thanks for making the change!

I'm supportive of the clone change