minimal dirfd implementation (1/4) #146341
Open
+607
−94
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is the first of four smaller PRs that will eventually be equivalent to #139514.
A few notes:
new
toopen
becauseopen_dir
takes&self
and opens a subdirectory.open
toopen_file
.impl AsRawFd
and friends because thecommon
implementation usesPathBuf
s. How should I proceed here?The other PRs will be based on this one, so I'll make drafts and mark them ready as their predecessors get merged. They might take a bit though; I've never done this particular thing with git before.
Tracking issue: #120426
r? @tgross35
try-job: aarch64-apple
try-job: dist-various*
try-job: test-various*
try-job: x86_64-msvc*
try-job: x86_64-msvc*
try-job: x86_64-mingw