Repository navigation
windows: stabilise inherit_handles - #161163
Conversation
21d6ccb to
5aeecbd
Compare
|
I'd like to bikeshed the name |
The current Unix equivalent is just I would prefer we keep the name I do however think we need to be sure that in stabilising this we aren't closing off any potential other APIs for handle inheritance. Or if we are then we're happy to do so. Should this override other APIs that may want to set it? Or should it be given the lowest priority? Or should it be a "last one wins" situation. |
|
I think this shouldn't exclude any other proposals and I see it as a convenience method that just so happens to be stabilisable before the more complex one. In my mind the semantics are that there is one list of handles to inherit, and this method has the effect of clearing/filling that list (so, last one wins). it would be shorthand for |
I would note that |
|
Thanks for starting this process (heh). I do think there is indeed something to figure out about the potential interactions it could have with such a future API. Personally, I find APIs that successfully abstract away from the lower-level stuff to be nice when they plug in well to the higher-level stuff (for example Rust semantics in general), but ones that explicitly don't do that in certain cases to be nicer if they regard relatively low-level stuff that is not very well controlled anyway. I think the current case could be akin to the latter. I guess a good way to decide that would be to determine the following: is there really a need to couple the two APIs together somehow? That is to say: what would happen if the two were to be implemented completely independently of one another in terms of low-level stuff? Would it lead to easily-avoidable errors or misuses that a better API could help remove entirely or would it just work, i.e. unused parameters are just ignored by the Windows API? That might require experimentation to be sure. Obviously, ignored parameters could be considered as a blocking issue by itself because they would represent a form of request or intent from the user that is not respected in the end, so could just lead to confusion. Listing the cases:
So in summary, both "Last one wins" could be a strategy to resolve the conflicting cases instead of this, but I'm not sure it would be the greatest if assigning particular semantics to each method is desired like done above. It would be much simpler though, so could be better than the above that could be deemed too convoluted and therefore hard to memorize. It would also be consistent with same-method repetitions. In any case though, I don't see how choosing any of these options could shape the current API differently? |
|
That does seem reasonable. I suppose the main concern that could block us stabilising the boolean method would be deciding to scrap it entirely and only go for a |
|
@rfcbot fcp merge libs,libs-api |
|
@the8472 has proposed to merge this. The next step is review by the rest of the tagged team members: No concerns currently listed. Once a majority of reviewers approve (and at most 2 approvals are outstanding), this will enter its final comment period. If you spot a major issue that hasn't been raised at any point in this process, please speak up! See this document for info about what commands tagged team members can give me. |
|
🔔 This is now entering its final comment period, as per the review above. 🔔 |
|
The final comment period, with a disposition to merge, as per the review above, is now complete. As the automated representative of the governance process, I would like to thank the author for their work and everyone else who contributed. |
|
@bors r+ rollup |
Rollup of 8 pull requests Successful merges: - #161163 (windows: stabilise inherit_handles) - #162615 (Add a `wasm32-none-component` target definition) - #163553 (DirEntry: warn about use potential races when fetching metadata or file_type) - #163618 ( Avoid ICE when closure expected signature contains non-lifetime bound variables ) - #163756 (xous: tcpstream fix timeout rounding with small and wrap large values) - #163818 (remove_dir_all: document and test symlink behavior more explicitly) - #163823 (enable fchmodat_works test under android) - #164596 (Update books)
Relevant to #161158; closes #146407 (by stabilising it). See my comment on the tracking issue.
r? libs