rustfmt v1.4.33 Release Notes
Release Date: 2021-01-27 // about 3 years ago-
๐ Changed
- ๐ง
merge_imports
configuration has been deprecated in favor of the newimports_granularity
option. Any existing usage ofmerge_imports
will be automatically mapped to the corresponding value onimports_granularity
with a warning message printed to encourage users to update their config files.
โ Added
- ๐ New
imports_granularity
option has been added which succeedsmerge_imports
. This new option supports several additional variants which allow users to merge imports at different levels (crate or module), and even flatten imports to have a single use statement per item. (PR #4634, PR #4639)
๐ See the section on the configuration site for more information https://rust-lang.github.io/rustfmt/?version=v1.4.33&search=#imports_granularity
๐ Fixed
- ๐ Fix erroneous removal of
const
keyword on const trait impl (#4084) - ๐ Fix incorrect span usage wit const generics in supertraits (#4204)
- ๐ Use correct span for const generic params (#4263)
- Correct span on const generics to include type bounds (#4310)
- Idempotence issue on blocks containing only empty statements (#4627 and #3868)
- ๐ Fix issue with semicolon placement on required functions that have a trailing comment that ends in a line-style comment before the semicolon (#4646)
- Avoid shared interned cfg_if symbol since rustfmt can re-initialize the rustc_ast globals on multiple inputs (#4656)
Install/Download Options
- ๐ฆ crates.io package - pending
- rustup (nightly) - n/a (superseded by v1.4.34)
- ๐ GitHub Release Binaries - Release v1.4.33
- ๐ Build from source - Tag v1.4.33, see instructions for how to [install rustfmt from source][install-from-source]
- ๐ง