2021-10-17 09:21:53 -05:00
|
|
|
// rustfmt-imports_granularity: Item
|
2022-04-16 06:12:27 -05:00
|
|
|
// rustfmt-group_imports: One
|
2021-10-17 09:21:53 -05:00
|
|
|
|
2022-04-16 06:12:27 -05:00
|
|
|
// Confirm that attributes are duplicated to all items in the use statement
|
2021-10-17 09:21:53 -05:00
|
|
|
#[cfg(feature = "foo")]
|
|
|
|
use std::collections::{
|
|
|
|
HashMap,
|
|
|
|
HashSet,
|
|
|
|
};
|
2022-04-16 06:12:27 -05:00
|
|
|
|
|
|
|
// Separate the imports below from the ones above
|
|
|
|
const A: usize = 0;
|
|
|
|
|
|
|
|
// Copying attrs works with import grouping as well
|
|
|
|
#[cfg(feature = "foo")]
|
|
|
|
use std::collections::{
|
|
|
|
HashMap,
|
|
|
|
HashSet,
|
|
|
|
};
|
|
|
|
|
|
|
|
#[cfg(feature = "spam")]
|
|
|
|
use qux::{bar, baz};
|