blob: ecf7c6850c13f9baf898e02c881b04da3f7f344f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
/// Required functionality for underlying [`std::io::Write`] for adaptation
#[cfg(not(any(feature = "auto", all(windows, feature = "wincon"))))]
pub trait RawStream: std::io::Write + private::Sealed {}
/// Required functionality for underlying [`std::io::Write`] for adaptation
#[cfg(all(feature = "auto", not(all(windows, feature = "wincon"))))]
pub trait RawStream: std::io::Write + is_terminal::IsTerminal + private::Sealed {}
/// Required functionality for underlying [`std::io::Write`] for adaptation
#[cfg(all(not(feature = "auto"), all(windows, feature = "wincon")))]
pub trait RawStream: std::io::Write + anstyle_wincon::WinconStream + private::Sealed {}
/// Required functionality for underlying [`std::io::Write`] for adaptation
#[cfg(all(feature = "auto", all(windows, feature = "wincon")))]
pub trait RawStream:
std::io::Write + is_terminal::IsTerminal + anstyle_wincon::WinconStream + private::Sealed
{
}
impl RawStream for std::io::Stdout {}
impl RawStream for std::io::StdoutLock<'static> {}
impl RawStream for std::io::Stderr {}
impl RawStream for std::io::StderrLock<'static> {}
impl RawStream for std::fs::File {}
impl RawStream for crate::Buffer {}
mod private {
pub trait Sealed {}
impl Sealed for std::io::Stdout {}
impl Sealed for std::io::StdoutLock<'static> {}
impl Sealed for std::io::Stderr {}
impl Sealed for std::io::StderrLock<'static> {}
impl Sealed for std::fs::File {}
impl Sealed for crate::Buffer {}
}
|