Skip to content

Is there some reason the 'FileTimes' and 'set_times' API is File only? #123883

@kimono-koans

Description

@kimono-koans

I don't see any discussion of this in the feature: #98245

Of course, it is possible the change the mtime and atime on a directory. However, this fails re: the current FileTimes API because one can't open a directory as one would a file.

Shouldn't the FileTimes API be available for all paths?

### Tasks

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-ioArea: `std::io`, `std::fs`, `std::net` and `std::path`C-discussionCategory: Discussion or questions that doesn't represent real issues.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions