Skip to content

stat.rs: Refactor to remove #[allow(clippy::cognitive_complexity)] #5881

@sylvestre

Description

@sylvestre

https://github.com/uutils/coreutils/blob/main/src/uu/stat/src/stat.rs#L407
A potential way to do it:

'%' => tokens.append(&mut handle_percent_case(&chars, &mut i, bound, format_str)?),
'\\' => tokens.append(&mut handle_escape_sequences(&chars, &mut i, bound, format_str, use_printf)),

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions