@@ -40,7 +40,6 @@ use crate::sys::anonymous_pipe::{AnonPipe, pipe as pipe_inner};
40
40
/// # Examples
41
41
///
42
42
/// ```no_run
43
- /// #![feature(anonymous_pipe)]
44
43
/// use std::process::Command;
45
44
/// use std::io::{pipe, Read, Write};
46
45
///
@@ -64,19 +63,19 @@ use crate::sys::anonymous_pipe::{AnonPipe, pipe as pipe_inner};
64
63
/// ```
65
64
/// [changes]: io#platform-specific-behavior
66
65
/// [man page]: https://man7.org/linux/man-pages/man7/pipe.7.html
67
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
66
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
68
67
#[ inline]
69
68
pub fn pipe ( ) -> io:: Result < ( PipeReader , PipeWriter ) > {
70
69
pipe_inner ( ) . map ( |( reader, writer) | ( PipeReader ( reader) , PipeWriter ( writer) ) )
71
70
}
72
71
73
72
/// Read end of an anonymous pipe.
74
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
73
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
75
74
#[ derive( Debug ) ]
76
75
pub struct PipeReader ( pub ( crate ) AnonPipe ) ;
77
76
78
77
/// Write end of an anonymous pipe.
79
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
78
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
80
79
#[ derive( Debug ) ]
81
80
pub struct PipeWriter ( pub ( crate ) AnonPipe ) ;
82
81
@@ -86,7 +85,6 @@ impl PipeReader {
86
85
/// # Examples
87
86
///
88
87
/// ```no_run
89
- /// #![feature(anonymous_pipe)]
90
88
/// use std::fs;
91
89
/// use std::io::{pipe, Write};
92
90
/// use std::process::Command;
@@ -131,7 +129,7 @@ impl PipeReader {
131
129
/// assert_eq!(xs, "x".repeat(NUM_PROC.into()));
132
130
/// # Ok::<(), std::io::Error>(())
133
131
/// ```
134
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
132
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
135
133
pub fn try_clone ( & self ) -> io:: Result < Self > {
136
134
self . 0 . try_clone ( ) . map ( Self )
137
135
}
@@ -143,7 +141,6 @@ impl PipeWriter {
143
141
/// # Examples
144
142
///
145
143
/// ```no_run
146
- /// #![feature(anonymous_pipe)]
147
144
/// use std::process::Command;
148
145
/// use std::io::{pipe, Read};
149
146
///
@@ -168,13 +165,13 @@ impl PipeWriter {
168
165
/// peer.wait()?;
169
166
/// # Ok::<(), std::io::Error>(())
170
167
/// ```
171
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
168
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
172
169
pub fn try_clone ( & self ) -> io:: Result < Self > {
173
170
self . 0 . try_clone ( ) . map ( Self )
174
171
}
175
172
}
176
173
177
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
174
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
178
175
impl io:: Read for & PipeReader {
179
176
fn read ( & mut self , buf : & mut [ u8 ] ) -> io:: Result < usize > {
180
177
self . 0 . read ( buf)
@@ -194,7 +191,7 @@ impl io::Read for &PipeReader {
194
191
}
195
192
}
196
193
197
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
194
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
198
195
impl io:: Read for PipeReader {
199
196
fn read ( & mut self , buf : & mut [ u8 ] ) -> io:: Result < usize > {
200
197
self . 0 . read ( buf)
@@ -214,7 +211,7 @@ impl io::Read for PipeReader {
214
211
}
215
212
}
216
213
217
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
214
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
218
215
impl io:: Write for & PipeWriter {
219
216
fn write ( & mut self , buf : & [ u8 ] ) -> io:: Result < usize > {
220
217
self . 0 . write ( buf)
@@ -232,7 +229,7 @@ impl io::Write for &PipeWriter {
232
229
}
233
230
}
234
231
235
- #[ unstable ( feature = "anonymous_pipe" , issue = "127154 " ) ]
232
+ #[ stable ( feature = "anonymous_pipe" , since = "CURRENT_RUSTC_VERSION " ) ]
236
233
impl io:: Write for PipeWriter {
237
234
fn write ( & mut self , buf : & [ u8 ] ) -> io:: Result < usize > {
238
235
self . 0 . write ( buf)
0 commit comments