@@ -121,7 +121,7 @@ pub struct File {
121
121
///
122
122
/// [`try_lock`]: File::try_lock
123
123
/// [`try_lock_shared`]: File::try_lock_shared
124
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
124
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
125
125
pub enum TryLockError {
126
126
/// The lock could not be acquired due to an I/O error on the file. The standard library will
127
127
/// not return an [`ErrorKind::WouldBlock`] error inside [`TryLockError::Error`]
@@ -367,10 +367,10 @@ pub fn write<P: AsRef<Path>, C: AsRef<[u8]>>(path: P, contents: C) -> io::Result
367
367
inner ( path. as_ref ( ) , contents. as_ref ( ) )
368
368
}
369
369
370
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
370
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
371
371
impl error:: Error for TryLockError { }
372
372
373
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
373
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
374
374
impl fmt:: Debug for TryLockError {
375
375
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
376
376
match self {
@@ -380,7 +380,7 @@ impl fmt::Debug for TryLockError {
380
380
}
381
381
}
382
382
383
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
383
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
384
384
impl fmt:: Display for TryLockError {
385
385
fn fmt ( & self , f : & mut fmt:: Formatter < ' _ > ) -> fmt:: Result {
386
386
match self {
@@ -391,7 +391,7 @@ impl fmt::Display for TryLockError {
391
391
}
392
392
}
393
393
394
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
394
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
395
395
impl From < TryLockError > for io:: Error {
396
396
fn from ( err : TryLockError ) -> io:: Error {
397
397
match err {
@@ -714,7 +714,6 @@ impl File {
714
714
/// # Examples
715
715
///
716
716
/// ```no_run
717
- /// #![feature(file_lock)]
718
717
/// use std::fs::File;
719
718
///
720
719
/// fn main() -> std::io::Result<()> {
@@ -723,7 +722,7 @@ impl File {
723
722
/// Ok(())
724
723
/// }
725
724
/// ```
726
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
725
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
727
726
pub fn lock ( & self ) -> io:: Result < ( ) > {
728
727
self . inner . lock ( )
729
728
}
@@ -767,7 +766,6 @@ impl File {
767
766
/// # Examples
768
767
///
769
768
/// ```no_run
770
- /// #![feature(file_lock)]
771
769
/// use std::fs::File;
772
770
///
773
771
/// fn main() -> std::io::Result<()> {
@@ -776,7 +774,7 @@ impl File {
776
774
/// Ok(())
777
775
/// }
778
776
/// ```
779
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
777
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
780
778
pub fn lock_shared ( & self ) -> io:: Result < ( ) > {
781
779
self . inner . lock_shared ( )
782
780
}
@@ -825,7 +823,6 @@ impl File {
825
823
/// # Examples
826
824
///
827
825
/// ```no_run
828
- /// #![feature(file_lock)]
829
826
/// use std::fs::{File, TryLockError};
830
827
///
831
828
/// fn main() -> std::io::Result<()> {
@@ -841,7 +838,7 @@ impl File {
841
838
/// Ok(())
842
839
/// }
843
840
/// ```
844
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
841
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
845
842
pub fn try_lock ( & self ) -> Result < ( ) , TryLockError > {
846
843
self . inner . try_lock ( )
847
844
}
@@ -889,7 +886,6 @@ impl File {
889
886
/// # Examples
890
887
///
891
888
/// ```no_run
892
- /// #![feature(file_lock)]
893
889
/// use std::fs::{File, TryLockError};
894
890
///
895
891
/// fn main() -> std::io::Result<()> {
@@ -906,7 +902,7 @@ impl File {
906
902
/// Ok(())
907
903
/// }
908
904
/// ```
909
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
905
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
910
906
pub fn try_lock_shared ( & self ) -> Result < ( ) , TryLockError > {
911
907
self . inner . try_lock_shared ( )
912
908
}
@@ -934,7 +930,6 @@ impl File {
934
930
/// # Examples
935
931
///
936
932
/// ```no_run
937
- /// #![feature(file_lock)]
938
933
/// use std::fs::File;
939
934
///
940
935
/// fn main() -> std::io::Result<()> {
@@ -944,7 +939,7 @@ impl File {
944
939
/// Ok(())
945
940
/// }
946
941
/// ```
947
- #[ unstable ( feature = "file_lock" , issue = "130994 " ) ]
942
+ #[ stable ( feature = "file_lock" , since = "CURRENT_RUSTC_VERSION " ) ]
948
943
pub fn unlock ( & self ) -> io:: Result < ( ) > {
949
944
self . inner . unlock ( )
950
945
}
0 commit comments