Add note on SpecOptionPartialEq to newtype_index
This commit is contained in:
parent
d78329b92e
commit
4ca6342eb3
2 changed files with 4 additions and 0 deletions
|
@ -31,6 +31,9 @@ mod newtype;
|
||||||
/// - `#[max = 0xFFFF_FFFD]`: specifies the max value, which allows niche
|
/// - `#[max = 0xFFFF_FFFD]`: specifies the max value, which allows niche
|
||||||
/// optimizations. The default max value is 0xFFFF_FF00.
|
/// optimizations. The default max value is 0xFFFF_FF00.
|
||||||
/// - `#[gate_rustc_only]`: makes parts of the generated code nightly-only.
|
/// - `#[gate_rustc_only]`: makes parts of the generated code nightly-only.
|
||||||
|
///
|
||||||
|
/// `SpecOptionPartialEq` is specialized by this macro, so using it requires enabling
|
||||||
|
/// `#![feature(min_specialization)]` for the crate.
|
||||||
#[proc_macro]
|
#[proc_macro]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "nightly",
|
feature = "nightly",
|
||||||
|
|
|
@ -2147,6 +2147,7 @@ impl<T: PartialEq> PartialEq for Option<T> {
|
||||||
///
|
///
|
||||||
/// Once that's fixed, `Option` should go back to deriving `PartialEq`, as
|
/// Once that's fixed, `Option` should go back to deriving `PartialEq`, as
|
||||||
/// it used to do before <https://github.com/rust-lang/rust/pull/103556>.
|
/// it used to do before <https://github.com/rust-lang/rust/pull/103556>.
|
||||||
|
/// The comment regarding this trait on the `newtype_index` macro should be removed if this is done.
|
||||||
#[unstable(feature = "spec_option_partial_eq", issue = "none", reason = "exposed only for rustc")]
|
#[unstable(feature = "spec_option_partial_eq", issue = "none", reason = "exposed only for rustc")]
|
||||||
#[doc(hidden)]
|
#[doc(hidden)]
|
||||||
pub trait SpecOptionPartialEq: Sized {
|
pub trait SpecOptionPartialEq: Sized {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue