Remove num_traits dependency. - #107
Conversation
|
Hi and thanks for the addition. I was not aware that the |
|
@jonaspleyer Thanks! To be totally honest, I have no idea why this dependency was there in the first place. I thought maybe it was for compatibility with older rust versions, but all the methods I checked were stable since 1.0, but I could have missed something. The only thing I can think of is that maybe when this was first written, it was based on blanket impls instead of macros. And when they moved to macros, they just brought this with them. But I really don't know. I'd be happy to spend some time looking into the history of it if it's important to you? |
|
The history is not too important to me to be honest. We should simply make sure that we do not accidentally break any form of compatibility. But I think that I will merge the code as is. Because the traits only appear inline in a function where it is encapsulated. Also, removing trait bounds on generics is generally backwards-compatible. |
|
Oh interesting! That's strange, too though. I wonder why they needed Anyway, should still be fine. I just tested it and it compiled for |
|
It appears like the original usage of |
It would be nice if we didn't need to pull in
num_traitsto use this.The only reason I can think of to not do this if it it would somehow not work on older rust versions.
But, I don't think this would actually cause any problems, and I didn't see a MSRV anywhere.
(
cargo testpasses locally. Let me know if there's any other test's you'd like me to run or anything!)