oli-obk / rust-pandoc

Apache License 2.0
51 stars 29 forks source link

A variety of `cargo check` and `cargo clippy` led cleanups #24

Closed kinnison closed 4 years ago

kinnison commented 4 years ago

I am working on some tooling which uses the rust-pandoc crate and as part of that will be submitting some functionality PRs over time. As a basis point though I thought it might be useful to bring the code to a point that it's warning/clippy clean and consistently formatted with cargo fmt so that further contributions are less risky for me as my editor auto-formats by default and I keep being caught out.

I've kept the changes as individual commits so that you can see what each bit is. Though I did combine the cargo fmt and cargo fix (Note, not cargo fix --edition) passes since they're automatic and can easily be replicated if you don't trust that's all I did (the diff for that commit is a bit big so can be hard to check by hand).

If this isn't wanted at all, please let me know, otherwise if you merge this, I'll follow up with one or two functionality PRs soon.

I didn't find any MSRV claims though I think none of the changes I made will cause problems for compilers post the 2018 edition. I've not bumped the edition in the Cargo.toml though since I felt that was a decision best left for you. If you want me to complete that too, let me know and I'll push an additional commit to the PR to do that.

oli-obk commented 4 years ago

This is awesome! thanks!

Yes, feel free to move to the 2018 edition, it should be in all major platforms nowadays