Skip to content

Add access to stdin, stdout, stderr names somehow #2778

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
tbu- opened this issue May 4, 2022 · 2 comments
Open

Add access to stdin, stdout, stderr names somehow #2778

tbu- opened this issue May 4, 2022 · 2 comments
Labels
C-API-request Category: API request E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Milestone

Comments

@tbu-
Copy link
Contributor

tbu- commented May 4, 2022

Earlier request: #7.
Implementation attempt: #1073.

One problem with this is that these names are apparently not symbols but only macros on some operating systems. (The C standard doesn't require these to be symbols.)

@tbu- tbu- added the C-API-request Category: API request label May 4, 2022
@thewh1teagle
Copy link

I also need to access stdout handle. Currently I'm using https://github.com/crlf0710/libc-stdhandle instead but I prefer to use it from this crate instead.
Does it possible already?

@tgross35 tgross35 added the E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. label Aug 29, 2024
@tgross35 tgross35 added this to the 1.x milestone Aug 29, 2024
@tbu-
Copy link
Contributor Author

tbu- commented May 5, 2025

@tgross35 Definitely not E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue. , it needs a decision on how to export identifiers only exposed as macros in C. errno seems to have gotten special treatment because it has libc::__errno_location, but an earlier attempt to copy that to stdin, stdout and stderr was rejected, see #1073 (comment) where it says we need an RFC to support stdin etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-API-request Category: API request E-easy Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Projects
None yet
Development

No branches or pull requests

3 participants