mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-09 20:07:01 +00:00
Run rustfmt
on nightly to clean up erroneous comments (#5106)
## Summary This PR runs `rustfmt` with a few nightly options as a one-time fix to catch some malformatted comments. I ended up just running with: ```toml condense_wildcard_suffixes = true edition = "2021" max_width = 100 normalize_comments = true normalize_doc_attributes = true reorder_impl_items = true unstable_features = true use_field_init_shorthand = true ``` Since these all seem like reasonable things to fix, so may as well while I'm here.
This commit is contained in:
parent
9ab16fb417
commit
716cab2f19
32 changed files with 49 additions and 34 deletions
|
@ -245,12 +245,11 @@ impl IndexKind {
|
|||
pub struct OneIndexed(NonZeroUsize);
|
||||
|
||||
impl OneIndexed {
|
||||
/// The largest value that can be represented by this integer type
|
||||
pub const MAX: Self = unwrap(Self::new(usize::MAX));
|
||||
// SAFETY: These constants are being initialized with non-zero values
|
||||
/// The smallest value that can be represented by this integer type.
|
||||
pub const MIN: Self = unwrap(Self::new(1));
|
||||
/// The largest value that can be represented by this integer type
|
||||
pub const MAX: Self = unwrap(Self::new(usize::MAX));
|
||||
|
||||
pub const ONE: NonZeroUsize = unwrap(NonZeroUsize::new(1));
|
||||
|
||||
/// Creates a non-zero if the given value is not zero.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue