Skip to content

std::io: impl IsTerminal for {Empty, Repeat, Sink, Take} - #161947

Open
GrigorenkoPV wants to merge 1 commit into
rust-lang:mainfrom
GrigorenkoPV:is_terminal
Open

std::io: impl IsTerminal for {Empty, Repeat, Sink, Take}#161947
GrigorenkoPV wants to merge 1 commit into
rust-lang:mainfrom
GrigorenkoPV:is_terminal

Conversation

@GrigorenkoPV

@GrigorenkoPV GrigorenkoPV commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Closes #161941

Yeah, these are instastable

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Aug 28, 2026
@rustbot

rustbot commented Aug 28, 2026

Copy link
Copy Markdown
Collaborator

r? @Mark-Simulacrum

rustbot has assigned @Mark-Simulacrum.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @ChrisDenton, libs
  • @ChrisDenton, libs expanded to 13 candidates
  • Random selection from ChrisDenton, JohnTitor, Mark-Simulacrum, clarfonthey, nia-e

@the8472 the8472 added the needs-fcp This change is insta-stable, or significant enough to need a team FCP to proceed. label Aug 28, 2026
@Mark-Simulacrum Mark-Simulacrum added S-waiting-on-t-libs Status: Awaiting decision from T-libs and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 30, 2026
@clarfonthey

Copy link
Copy Markdown
Contributor

@rfcbot fcp merge libs

@rust-rfcbot

rust-rfcbot commented Aug 30, 2026

Copy link
Copy Markdown
Collaborator

@clarfonthey has proposed to merge this. The next step is review by the rest of the tagged team members:

Concerns:

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.

@rust-rfcbot rust-rfcbot added proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. and removed needs-fcp This change is insta-stable, or significant enough to need a team FCP to proceed. labels Aug 30, 2026
@clarfonthey clarfonthey added S-waiting-on-fcp Status: PR is in FCP and is awaiting for FCP to complete. T-libs Relevant to the library team, which will review and decide on the PR/issue. and removed T-libs Relevant to the library team, which will review and decide on the PR/issue. S-waiting-on-t-libs Status: Awaiting decision from T-libs labels Aug 31, 2026
@joshtriplett

Copy link
Copy Markdown
Member

We might also want to implement it for BufReader<R> and BufWriter<W> if the underlying types implement IsTerminal, and pass it through.

@the8472

the8472 commented Sep 1, 2026

Copy link
Copy Markdown
Member

@rfcbot concern always-false

Depending on which semantics we agree to document in #162012 it might not want this for Sink if it always returns false.

@GrigorenkoPV

GrigorenkoPV commented Sep 1, 2026

Copy link
Copy Markdown
Contributor Author

We might also want to implement it for BufReader<R> and BufWriter<W> if the underlying types implement IsTerminal, and pass it through.

Those two are in alloc with inner being a private field, while IsTerminal is a sealed trait in std. So this will require some non-obvious rearranging.


Some peculiar trivia: BufWriter<T> has T: ?Sized + Write, BufReader<T> has T: ?Sized (no + Read), Take<T> has T (no : ?Sized or : Read).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

disposition-merge This issue / PR is in PFCP or FCP with a disposition to merge it. proposed-final-comment-period Proposed to merge/close by relevant subteam, see T-<team> label. Will enter FCP once signed off. S-waiting-on-fcp Status: PR is in FCP and is awaiting for FCP to complete. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature request: std::io::Sink should implement std::io::IsTerminal (returning false)

7 participants