Rollup merge of #97950 - eggyal:issue-97945, r=Dylan-DPC

Clarify `#[derive(PartialEq)]` on enums

Fixes #97945
This commit is contained in:
Michael Goulet
2022-06-12 17:35:41 -07:00
committed by GitHub
+2 -2
View File
@@ -61,8 +61,8 @@
///
/// This trait can be used with `#[derive]`. When `derive`d on structs, two
/// instances are equal if all fields are equal, and not equal if any fields
/// are not equal. When `derive`d on enums, each variant is equal to itself
/// and not equal to the other variants.
/// are not equal. When `derive`d on enums, two instances are equal if they
/// are the same variant and all fields are equal.
///
/// ## How can I implement `PartialEq`?
///