Remove use of #[rustc_deprecated]
This commit is contained in:
parent
8ff5e3cf99
commit
4fbe73e0b7
77 changed files with 274 additions and 356 deletions
|
@ -39,7 +39,7 @@ pub use core::ascii::{escape_default, EscapeDefault};
|
|||
///
|
||||
/// [combining character]: https://en.wikipedia.org/wiki/Combining_character
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(since = "1.26.0", reason = "use inherent methods instead")]
|
||||
#[deprecated(since = "1.26.0", note = "use inherent methods instead")]
|
||||
pub trait AsciiExt {
|
||||
/// Container type for copied ASCII characters.
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
|
|
|
@ -402,7 +402,7 @@
|
|||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
// FIXME(#82080) The deprecation here is only theoretical, and does not actually produce a warning.
|
||||
#[rustc_deprecated(reason = "moved to `std::ops::Bound`", since = "1.26.0")]
|
||||
#[deprecated(note = "moved to `std::ops::Bound`", since = "1.26.0")]
|
||||
#[doc(hidden)]
|
||||
pub use crate::ops::Bound;
|
||||
|
||||
|
|
|
@ -577,10 +577,10 @@ impl Error for JoinPathsError {
|
|||
/// None => println!("Impossible to get your home dir!"),
|
||||
/// }
|
||||
/// ```
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.29.0",
|
||||
reason = "This function's behavior is unexpected and probably not what you want. \
|
||||
Consider using a crate from crates.io instead."
|
||||
note = "This function's behavior is unexpected and probably not what you want. \
|
||||
Consider using a crate from crates.io instead."
|
||||
)]
|
||||
#[must_use]
|
||||
#[stable(feature = "env", since = "1.0.0")]
|
||||
|
|
|
@ -143,15 +143,15 @@ pub trait Error: Debug + Display {
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(since = "1.42.0", reason = "use the Display impl or to_string()")]
|
||||
#[deprecated(since = "1.42.0", note = "use the Display impl or to_string()")]
|
||||
fn description(&self) -> &str {
|
||||
"description() is deprecated; use Display"
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.33.0",
|
||||
reason = "replaced by Error::source, which can support downcasting"
|
||||
note = "replaced by Error::source, which can support downcasting"
|
||||
)]
|
||||
#[allow(missing_docs)]
|
||||
fn cause(&self) -> Option<&dyn Error> {
|
||||
|
|
|
@ -511,15 +511,15 @@ impl f32 {
|
|||
#[must_use = "method returns a new number and does not mutate the original value"]
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[inline]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.10.0",
|
||||
reason = "you probably meant `(self - other).abs()`: \
|
||||
this operation is `(self - other).max(0.0)` \
|
||||
except that `abs_sub` also propagates NaNs (also \
|
||||
known as `fdimf` in C). If you truly need the positive \
|
||||
difference, consider using that expression or the C function \
|
||||
`fdimf`, depending on how you wish to handle NaN (please consider \
|
||||
filing an issue describing your use-case too)."
|
||||
note = "you probably meant `(self - other).abs()`: \
|
||||
this operation is `(self - other).max(0.0)` \
|
||||
except that `abs_sub` also propagates NaNs (also \
|
||||
known as `fdimf` in C). If you truly need the positive \
|
||||
difference, consider using that expression or the C function \
|
||||
`fdimf`, depending on how you wish to handle NaN (please consider \
|
||||
filing an issue describing your use-case too)."
|
||||
)]
|
||||
pub fn abs_sub(self, other: f32) -> f32 {
|
||||
unsafe { cmath::fdimf(self, other) }
|
||||
|
|
|
@ -513,15 +513,15 @@ impl f64 {
|
|||
#[must_use = "method returns a new number and does not mutate the original value"]
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[inline]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.10.0",
|
||||
reason = "you probably meant `(self - other).abs()`: \
|
||||
this operation is `(self - other).max(0.0)` \
|
||||
except that `abs_sub` also propagates NaNs (also \
|
||||
known as `fdim` in C). If you truly need the positive \
|
||||
difference, consider using that expression or the C function \
|
||||
`fdim`, depending on how you wish to handle NaN (please consider \
|
||||
filing an issue describing your use-case too)."
|
||||
note = "you probably meant `(self - other).abs()`: \
|
||||
this operation is `(self - other).max(0.0)` \
|
||||
except that `abs_sub` also propagates NaNs (also \
|
||||
known as `fdim` in C). If you truly need the positive \
|
||||
difference, consider using that expression or the C function \
|
||||
`fdim`, depending on how you wish to handle NaN (please consider \
|
||||
filing an issue describing your use-case too)."
|
||||
)]
|
||||
pub fn abs_sub(self, other: f64) -> f64 {
|
||||
unsafe { cmath::fdim(self, other) }
|
||||
|
|
|
@ -1851,10 +1851,10 @@ pub fn hard_link<P: AsRef<Path>, Q: AsRef<Path>>(original: P, link: Q) -> io::Re
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.1.0",
|
||||
reason = "replaced with std::os::unix::fs::symlink and \
|
||||
std::os::windows::fs::{symlink_file, symlink_dir}"
|
||||
note = "replaced with std::os::unix::fs::symlink and \
|
||||
std::os::windows::fs::{symlink_file, symlink_dir}"
|
||||
)]
|
||||
pub fn soft_link<P: AsRef<Path>, Q: AsRef<Path>>(original: P, link: Q) -> io::Result<()> {
|
||||
fs_imp::symlink(original.as_ref(), link.as_ref())
|
||||
|
|
|
@ -915,20 +915,14 @@ impl TcpListener {
|
|||
}
|
||||
|
||||
#[stable(feature = "net2_mutators", since = "1.9.0")]
|
||||
#[rustc_deprecated(
|
||||
since = "1.16.0",
|
||||
reason = "this option can only be set before the socket is bound"
|
||||
)]
|
||||
#[deprecated(since = "1.16.0", note = "this option can only be set before the socket is bound")]
|
||||
#[allow(missing_docs)]
|
||||
pub fn set_only_v6(&self, only_v6: bool) -> io::Result<()> {
|
||||
self.0.set_only_v6(only_v6)
|
||||
}
|
||||
|
||||
#[stable(feature = "net2_mutators", since = "1.9.0")]
|
||||
#[rustc_deprecated(
|
||||
since = "1.16.0",
|
||||
reason = "this option can only be set before the socket is bound"
|
||||
)]
|
||||
#[deprecated(since = "1.16.0", note = "this option can only be set before the socket is bound")]
|
||||
#[allow(missing_docs)]
|
||||
pub fn only_v6(&self) -> io::Result<bool> {
|
||||
self.0.only_v6()
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Android-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Dragonfly-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -3,12 +3,12 @@
|
|||
//! except using the musl-specific stat64 structure in liblibc.
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -12,10 +12,10 @@ use crate::os::espidf::raw;
|
|||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
pub trait MetadataExt {
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Raw type definitions for the ESP-IDF framework.
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
|
||||
use crate::os::raw::c_long;
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! FreeBSD-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Fuchsia-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Haiku-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.53.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,9 +18,9 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor methods of this trait"
|
||||
note = "deprecated in favor of the accessor methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
//! illumos-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by the standard library, the `libc` \
|
||||
note = "these type aliases are no longer supported by the standard library, the `libc` \
|
||||
crate on crates.io should be used instead for the correct definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! iOS-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ pub trait MetadataExt {
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(since = "1.8.0", reason = "other methods of this trait are now preferred")]
|
||||
#[deprecated(since = "1.8.0", note = "other methods of this trait are now preferred")]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! L4Re-specific raw type definitions.
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ pub trait MetadataExt {
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(since = "1.8.0", reason = "other methods of this trait are now preferred")]
|
||||
#[deprecated(since = "1.8.0", note = "other methods of this trait are now preferred")]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Linux-specific raw type definitions.
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! macOS-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! NetBSD-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! OpenBSD-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -34,10 +34,10 @@ pub trait MetadataExt {
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Redox-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -18,10 +18,10 @@ pub trait MetadataExt {
|
|||
/// Unix platforms. The `os::unix::fs::MetadataExt` trait contains the
|
||||
/// cross-Unix abstractions contained within the raw stat.
|
||||
#[stable(feature = "metadata_ext", since = "1.1.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
note = "deprecated in favor of the accessor \
|
||||
methods of this trait"
|
||||
)]
|
||||
#[allow(deprecated)]
|
||||
fn as_raw_stat(&self) -> &raw::stat;
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Solaris-specific raw type definitions
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -103,7 +103,7 @@ pub trait CommandExt: Sealed {
|
|||
///
|
||||
/// [`pre_exec`]: CommandExt::pre_exec
|
||||
#[stable(feature = "process_exec", since = "1.15.0")]
|
||||
#[rustc_deprecated(since = "1.37.0", reason = "should be unsafe, use `pre_exec` instead")]
|
||||
#[deprecated(since = "1.37.0", note = "should be unsafe, use `pre_exec` instead")]
|
||||
fn before_exec<F>(&mut self, f: F) -> &mut process::Command
|
||||
where
|
||||
F: FnMut() -> io::Result<()> + Send + Sync + 'static,
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
//! Unix-specific primitives available on all unix platforms.
|
||||
|
||||
#![stable(feature = "raw_ext", since = "1.1.0")]
|
||||
#![rustc_deprecated(
|
||||
#![deprecated(
|
||||
since = "1.8.0",
|
||||
reason = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
note = "these type aliases are no longer supported by \
|
||||
the standard library, the `libc` crate on \
|
||||
crates.io should be used instead for the correct \
|
||||
definitions"
|
||||
)]
|
||||
#![allow(deprecated)]
|
||||
|
||||
|
|
|
@ -303,7 +303,7 @@ impl Condvar {
|
|||
/// }
|
||||
/// ```
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(since = "1.6.0", reason = "replaced by `std::sync::Condvar::wait_timeout`")]
|
||||
#[deprecated(since = "1.6.0", note = "replaced by `std::sync::Condvar::wait_timeout`")]
|
||||
pub fn wait_timeout_ms<'a, T>(
|
||||
&self,
|
||||
guard: MutexGuard<'a, T>,
|
||||
|
|
|
@ -152,9 +152,9 @@ pub struct OnceState {
|
|||
/// static START: Once = ONCE_INIT;
|
||||
/// ```
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(
|
||||
#[deprecated(
|
||||
since = "1.38.0",
|
||||
reason = "the `new` function is now preferred",
|
||||
note = "the `new` function is now preferred",
|
||||
suggestion = "Once::new()"
|
||||
)]
|
||||
pub const ONCE_INIT: Once = Once::new();
|
||||
|
|
|
@ -786,7 +786,7 @@ pub fn panicking() -> bool {
|
|||
/// thread::sleep_ms(2000);
|
||||
/// ```
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(since = "1.6.0", reason = "replaced by `std::thread::sleep`")]
|
||||
#[deprecated(since = "1.6.0", note = "replaced by `std::thread::sleep`")]
|
||||
pub fn sleep_ms(ms: u32) {
|
||||
sleep(Duration::from_millis(ms as u64))
|
||||
}
|
||||
|
@ -940,7 +940,7 @@ pub fn park() {
|
|||
///
|
||||
/// See the [park documentation][`park`] for more detail.
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
#[rustc_deprecated(since = "1.6.0", reason = "replaced by `std::thread::park_timeout`")]
|
||||
#[deprecated(since = "1.6.0", note = "replaced by `std::thread::park_timeout`")]
|
||||
pub fn park_timeout_ms(ms: u32) {
|
||||
park_timeout(Duration::from_millis(ms as u64))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue