Repository navigation
Conversation
| let use_printf = matches.contains_id(options::PRINTF); | ||
| // An empty format given by the user is still used instead of the default. | ||
| let user_format = matches | ||
| .get_one::<String>(if use_printf { |
There was a problem hiding this comment.
the same if use_printf { PRINTF } else { FORMAT } is in given_option below, could be a single variable, no?
There was a problem hiding this comment.
Yes, it is a single format_option now, used for both.
Merging this PR will degrade performance by 86.77%1 warning, 1 note
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing Footnotes
|
* tests/stat/stat-printf.pl (f-empty, f-empty2, f-empty-terse) (p-empty, fs-empty): New tests, ensuring an empty format is used rather than the default one. uutils/coreutils#16451 Link: #464
An empty format was taken as "no format given", so
stat -c ''andstat --printf=printed the default format. Like GNU, the default is now only used when neither option is given, so-c ''prints just the newline and--printf=prints nothing.Closes #16450