dropbox / rust-brotli

Brotli compressor and decompressor written in rust that optionally avoids the stdlib
https://dropbox.tech/infrastructure/-broccoli--syncing-faster-by-syncing-less
BSD 3-Clause "New" or "Revised" License
812 stars 83 forks source link

Reorganize `use` statements, rm `unused_imports` #182

Closed nyurik closed 4 months ago

nyurik commented 5 months ago

This PR is a follow up to #180. If you merge it first, this PR will be much smaller, and easier to see the manual changes. Or just apply this one directly and close #180.

No code changes - only re-sorting the use and extern declarations.

I used unstable nightly fmt for this PR, which is a superset of the standard fmt -- so CI would pass this, and once in a while we can re-run these commands to keep things tidier.

cargo +nightly fmt -- --config imports_granularity=Module,group_imports=StdExternalCrate
cd c && cargo +nightly fmt -- --config imports_granularity=Module,group_imports=StdExternalCrate

Note that the above steps can also be done with just fmt2

nyurik commented 5 months ago

@danielrh when you have a chance, please merge this one first because it is fairly tricky to keep rebasing it. This is a noop - it just moves the use statements around to make them more readable - and makes it possible to remove dead code and unused lints in the future. Thx!