Re: [PATCH v3 04/13] rust: hrtimer: implement `TimerPointer` for `Arc`

From: Miguel Ojeda
Date: Fri Nov 22 2024 - 07:36:52 EST


On Wed, Nov 20, 2024 at 4:52 PM Andreas Hindborg <a.hindborg@xxxxxxxxxx> wrote:
>
> No particular reason. It is often easier to rebase things around when
> they are on their own line.
>
> Are there any code guidelines to follow on this?

Not yet -- we have a mixture of styles, though we typically don't go
to the item-level like in this patch, and instead have done it closer
to the "Crate" or "Module" styles.

Ideally we would automate at least to some degree, but currently the
relevant `rustfmt` options are unstable:

https://rust-lang.github.io/rustfmt/#imports_indent
https://rust-lang.github.io/rustfmt/#imports_layout
https://rust-lang.github.io/rustfmt/#imports_granularity
https://rust-lang.github.io/rustfmt/#group_imports

I agree that deciding on one style would be nice (especially if it is
reasonable to expect that the style would be eventually supported by
`rustfmt`).

Cheers,
Miguel