Skip to content

Commit 68cfd58

Browse files
committed
Auto merge of #65690 - flip1995:readd_derives_clippy, r=Centril
Readd some PartialEq and Hash derives used by Clippy cc #65647 r? @Centril cc @Manishearth
2 parents 57bfb80 + 67c8a0f commit 68cfd58

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/libsyntax/ast.rs

+6-3
Original file line numberDiff line numberDiff line change
@@ -1305,7 +1305,8 @@ impl MacroDef {
13051305
}
13061306
}
13071307

1308-
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy)]
1308+
// Clippy uses Hash and PartialEq
1309+
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy, Hash, PartialEq)]
13091310
pub enum StrStyle {
13101311
/// A regular string, like `"foo"`.
13111312
Cooked,
@@ -1327,7 +1328,8 @@ pub struct Lit {
13271328
pub span: Span,
13281329
}
13291330

1330-
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy)]
1331+
// Clippy uses Hash and PartialEq
1332+
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Copy, Hash, PartialEq)]
13311333
pub enum LitIntType {
13321334
Signed(IntTy),
13331335
Unsigned(UintTy),
@@ -1337,7 +1339,8 @@ pub enum LitIntType {
13371339
/// Literal kind.
13381340
///
13391341
/// E.g., `"foo"`, `42`, `12.34`, or `bool`.
1340-
#[derive(Clone, RustcEncodable, RustcDecodable, Debug)]
1342+
// Clippy uses Hash and PartialEq
1343+
#[derive(Clone, RustcEncodable, RustcDecodable, Debug, Hash, PartialEq)]
13411344
pub enum LitKind {
13421345
/// A string literal (`"foo"`).
13431346
Str(Symbol, StrStyle),

src/tools/clippy

0 commit comments

Comments
 (0)